Jimmy Alvarez
01/23/2018, 4:07 PMClayton Walker
01/23/2018, 7:59 PM@SpringBootApplication
class DemoApplication
fun main(args: Array<String>) {
runApplication<DemoApplication>(*args)
}
Shawn
01/23/2018, 8:01 PMansman
01/23/2018, 10:22 PMinternal
class from a unit test in the same module. Android Studio shows no issues but when I try to compile I just get Cannot access 'XXX': it is internal in 'YYY'
. This is using Kotlin 1.2.20jschneider
01/23/2018, 10:41 PMafernan
01/24/2018, 1:02 AMziggy42
01/24/2018, 1:10 PMdh44t
01/24/2018, 3:18 PMmkodekar
01/24/2018, 3:23 PMmenegatti
01/24/2018, 3:24 PMcurrentTotal
is always equal to the final before
, right?
so
val list = some.things.map {
Something.fromOtherThing(it, currentTotal, currentTotal - it.amount).also {
currentTotal -= it.amount
}
}
val currentTotal = list.last().thirdParameter
should workziggy42
01/24/2018, 3:26 PMziggy42
01/24/2018, 3:27 PMraulraja
01/24/2018, 4:42 PMlist
using both handlers
and ErrorHandler
type information and computing the intersection based on the hierarchy of those two applied types. In the first case handlers
uses an interface that declares type arguments in contravariant position in
. The compiler seems to be fine finding the intersection but it's bailing at runtime so the generated bytecode is probably incorrect where it has to do the appropriate cast but this last part is a wild guess.aidanvii
01/24/2018, 4:42 PMcedric
01/24/2018, 7:55 PMJoshua F
01/24/2018, 10:47 PMFunction1<A, Unit>
I believe?kevinmost
01/24/2018, 10:50 PMreturn Unit.INSTANCE;
to the slightly less ugly return null;
diesieben07
01/25/2018, 9:31 AMServiceLoader
for pure Kotlin, i.e. can be used in a multiplatform project?mike_shysh
01/25/2018, 1:04 PMNizzle94
01/25/2018, 2:48 PMnickk
01/25/2018, 3:18 PMRange
to an array?
There is no reduce
function for Ranges, and although this works, it feels a bit awkward:
(0..frames).forEach { i -> duration += animation?.getDuration(i)!! }
menegatti
01/25/2018, 3:21 PMval frameDurationArray = IntArray(frames + 1) { animation?.getDuration(it)!! }
val duration = frameDurationArray.sum()
zmarkan
01/25/2018, 4:50 PMcedric
01/25/2018, 7:01 PMCzar
01/25/2018, 7:41 PMOlekss
01/26/2018, 8:23 AMOlekss
01/26/2018, 10:27 AMrrader
01/26/2018, 1:06 PMOlekss
01/26/2018, 1:41 PMarekolek
01/26/2018, 5:21 PMoperator
before the fun
arekolek
01/26/2018, 5:21 PMoperator
before the fun
dmulligan
01/26/2018, 5:42 PM