Czar
11/28/2017, 10:52 AMfun AbstractPartial.isBeforeOrEqual(other: ReadablePartial): Boolean = !isAfter(other)
fun AbstractPartial.isAfterOrEqual(other: ReadablePartial): Boolean = !isBefore(other)
The problem with directly using something like !isAfter(other)
is the exclamation mark, arguably it is harder to spot and read than readable name like isBeforeOrEqual(other)
.louiscad
11/28/2017, 10:55 AMinline
since it's a simple method callCzar
11/28/2017, 10:59 AMlouiscad
11/28/2017, 11:07 AM@file:Suppress("NOTHING_TO_INLINE")
to the rescue! Note that some "JVM"s don't have JIT. Examples are Android 5.0, 5.1 and 6.0. Android 7.0 and 8.0 have only a partial JITCzar
11/28/2017, 11:10 AMCzar
11/28/2017, 11:12 AMlouiscad
11/28/2017, 11:15 AMCzar
11/28/2017, 11:19 AMinline
here, so I happily oblige without suppressing stuff, disabling inspections, etc.dave08
11/28/2017, 1:39 PMoperator
<
, etc...? 😉Czar
11/28/2017, 5:43 PM