Ajay
09/15/2018, 1:01 PMAngad
09/27/2018, 9:02 PMAngad
10/13/2018, 10:13 AMRohan Maity
01/17/2019, 2:27 AMtailrec
keyword works . I mean how it converts the tail call optimised recursion to iterative oneGopal S Akshintala
07/28/2021, 6:08 AMerror: cannot find symbol
# Kotlin Value class
import io.vavr.control.Either
import io.vavr.kotlin.right
@JvmInline
value class Name(val s: String) {
val length: Int
get() = s.length
}
fun getAsName(): Either<String, Name> = right(Name("Kotlin"))
# Java Client
@Test
void testValueClass() {
final var name = getAsName().get();
Assertions.assertEquals(0, name.getLength());
}
# Error
error: cannot find symbol
Assertions.assertEquals(0, name.getLength());
^
symbol: method getLength()
location: variable name of type Name
Thread in Slack ConversationMohanraj Sampath
08/10/2021, 6:33 AMMohanraj Sampath
08/10/2021, 6:35 AMGopal S Akshintala
08/31/2021, 5:44 AMCollectionsKt
method directly in java and run this in a unit test. However this static import is causing this exception
import static kotlin.collections.CollectionsKt.chunked;
However, if I use CollectionsKt.chunked(…)
without the static import, I don’t get this exception:
java.lang.IllegalAccessError: failed to access class kotlin.collections.CollectionsKt___CollectionsKt from class billing.batch.invoice.services.tax.TaxIntegrator (kotlin.collections.CollectionsKt___CollectionsKt and billing.batch.invoice.services.tax.TaxIntegrator are in unnamed module of loader org.powermock2.core.classloader.javassist.JavassistMockClassLoader @5443d039)
Slack ConversationKamila
03/23/2022, 9:18 AMAndré Martins
06/06/2022, 3:53 PMjava.lang.InternalError: java.io.FileNotFoundException: /Library/Java/JavaVirtualMachines/adoptopenjdk-11.jdk/Contents/Home/lib/currency.data (No such file or directory)
I’ve looked at this but couldn’t find muchwakingrufus
07/21/2022, 3:10 PMgetLogging()
in 1 version and just a property called logging
in the next, and when i compile against the former, running against the latter fails b/c its looking for a getter method stillSai krishna Daruvuri
12/15/2022, 6:43 PMClaude Brisson
02/26/2023, 8:23 AMVáclav Benes
07/19/2024, 1:10 PMvar POINT_2D: MemoryLayout = MemoryLayout.structLayout(
JAVA_DOUBLE.withName("x"),
JAVA_DOUBLE.withName("y")
)
val handle_x: VarHandle = POINT_2D.varHandle(PathElement.groupElement("x"))
val handle_y: VarHandle = POINT_2D.varHandle(PathElement.groupElement("y"))
// This doesn't work in java 22
fun main() {
Arena.ofConfined().use { arena ->
val point = arena.allocate(POINT_2D)
handle_x.set(point, 11)
handle_y.set(point, 22)
handle_x.get(point).also { println(it) }
handle_y.get(point).also { println(it) }
}
}