themishkun
08/20/2019, 8:47 AM@Composable
fun foo() {
+onActive {
(0..10).maxWith(Comparator<Int> { a, b -> a.compareTo(b) })
}
}
this code above throws long compilation error
but this code below runs fine
@Composable
fun foo() {
+onActive {
(0..10).maxWith(object : Comparator<Int> {
override fun compare(a: Int, b: Int): Int {
return a.compareTo(b)
}
})
}
}
Luca Nicoletti
08/20/2019, 8:52 AMthemishkun
08/20/2019, 8:54 AMLuca Nicoletti
08/20/2019, 9:00 AMjim
08/26/2019, 5:43 PMLuca Nicoletti
08/26/2019, 5:46 PM