voddan
02/19/2017, 5:13 PMvoddan
02/25/2017, 6:16 PMIncompatible classes were found in dependencies. Remove them from the classpath or use '-Xskip-metadata-version-check' to suppress errors
[ERROR] /Users/voddan/Programming/kotlin/libraries/stdlib/src/generated/_Arrays.kt: (1, 7) Class 'kotlin.jvm.JvmMultifileClass' is compiled by a pre-release version of Kotlin and cannot be loaded by this version of the compiler
What is the recommended way to deal with it?Dmitry Kandalov
03/10/2017, 5:48 PMapatrida
03/14/2017, 6:36 PMilya.gorbunov
04/08/2017, 9:19 AMlibraries
directory: now you need to run gradle build step before running maven. More details in the readme: https://github.com/JetBrains/kotlin/blob/master/libraries/ReadMe.md
And if you work solely on the standard library, it's enough to run just gradle build.kirillrakhman
05/02/2017, 12:55 PMkirillrakhman
05/17/2017, 4:35 PMkirillrakhman
05/22/2017, 9:20 PMpozo
05/31/2017, 8:04 AMINDICES
andrewreitz
05/31/2017, 7:23 PMuli
05/31/2017, 7:30 PMtypealias NumberType = Double
inline fun Number.toNumberType() = when (NumberType::class) {
Double::class -> this.toDouble() as NumberType
Float::class -> this.toFloat() as NumberType
Long::class -> this.toLong() as NumberType
Int::class -> this.toInt() as NumberType
Short::class -> this.toShort() as NumberType
Byte::class -> this.toByte() as NumberType
else -> throw IllegalArgumentException("NumberType must be in [Double, Float, Long, Int, Short, Byte]")
}
Looking at the decompiled java code, it generates all when
branches, not noticing, that only one will ever be selected.
Is this expected or should i report?
Slack Conversationeddie
06/04/2017, 4:43 PMshubham2892
06/11/2017, 5:49 PMclass TestTestTest(val param: String)
-> class TestTestTest
instead of class TestTestTest()
. I have been able to do so by these changes(https://github.com/shubham2892/kotlin/commit/1b8674496721d301819fdbc17ce1eeda27a83775) but I am getting the above error. I am having hardtime understanding how the runSignature
method call is acquiring the write lock.yole
06/12/2017, 10:43 AMevanchooly
06/15/2017, 3:35 AMneworldlt
06/15/2017, 9:25 AMgildor
06/22/2017, 1:55 AMkirillrakhman
06/28/2017, 6:10 PMcom.intellij.codeInspection.LocalQuickFix
be disabled? It doesn't seem to have an isAvilable
functionvkkoshelev
07/02/2017, 5:30 PMtieskedh
07/10/2017, 8:27 PMeddie
07/21/2017, 2:43 AMwhen
is here: https://github.com/JetBrains/kotlin/blob/master/compiler/frontend/src/org/jetbrains/kotlin/parsing/KotlinExpressionParsing.java#L839Eugenio
08/02/2017, 5:43 PMabstract class A<T>
class B : A<Callable<String>>()
Then the correct @Metadata
annotation is generated on `B`:
@Metadata(
mv = {1, 1, 6},
bv = {1, 0, 1},
k = 1,
d1 = {"\u0000\u0014\n\u0002\u0018\u0002\n\u0002\u0018\u0002\n\u0002\u0018\u0002\n\u0002\u0010\u000e\n\u0002\b\u0002\u0018\u00002\u000e\u0012\n\u0012\b\u0012\u0004\u0012\u00020\u00030\u00020\u0001B\u0005¢\u0006\u0002\u0010\u0004¨\u0006\u0005"},
d2 = {"LB;", "LA;", "Ljava/util/concurrent/Callable;", "", "()V", "production sources for module app_main"}
)
(notice the reference to Ljava/util/concurrent/Callable
)
Now when this code is compiled instead:
abstract class A<T>
inline fun <reified T> a() = object : A<T>() {}
val B = a<Callable<String>>()
Then this @Metadata
annotation is generated on the anonymous class:
@Metadata(
mv = {1, 1, 6},
bv = {1, 0, 1},
k = 1,
d1 = {"\u0000\r\n\u0000\n\u0002\u0018\u0002\n\u0002\b\u0002*\u0001\u0000\b\n\u0018\u00002\b\u0012\u0004\u0012\u00028\u00000\u0001B\u0005¢\u0006\u0002\u0010\u0002¨\u0006\u0003"},
d2 = {"TestKt$a$1", "LA;", "()V", "production sources for module app_main"}
)
All type information is completely lost... Is that the intended behaviour? Can this be avoided?jw
08/11/2017, 8:32 PMraulraja
08/13/2017, 4:57 PMkotlinc
and feeding it snippets to verify they can be compiled. Is there a way to also evaluate expressions and obtain their results in the same way the kotlinc
REPL does? Any help or pointers in the right direction are appreciated 🙂jimn
08/14/2017, 6:13 AMaoriani
08/14/2017, 9:09 PMmarcinmoskala
08/19/2017, 12:29 PMclass A {
@get:Arg val a: Int by BoundToValueDelegateProvider()
}
Inside provideDelegate
I have property reference
operator fun provideDelegate(
thisRef: Any?,
prop: KProperty<*>
): ReadWriteProperty<Any, T> {
val annotation1 = prop.getter.findAnnotation<Arg>() // This is null
val annotation2 = prop.javaGetter?.getAnnotation(Arg::class.java) // This is null too
// ...
}
It this bug or expected behavior?orangy
bsideup
08/23/2017, 2:56 PMRoman Ivanov
08/24/2017, 3:47 PM