hastebrot
12/29/2015, 11:52 PMfun foo...
were so much simpler. It just needed the tokens Keyword
, Text
and Name::Function
and pop the state back to the root rules. fun <T...> foo(...)
is much more complicated, because we need to copy a subset of the root rules for the tokens between Keyword
(fun) and Name::Function
.hastebrot
12/29/2015, 11:54 PMfun <T> foo()
and two different declaration styles were too many.hastebrot
12/30/2015, 12:08 AMfun <reified T : Any> ...
.benny_wang
12/30/2015, 5:46 AMrokee
12/30/2015, 9:29 AMmodule.itemsType?.length > 0) <- occurs an error
rokee
12/30/2015, 9:29 AMrokee
12/30/2015, 9:30 AMUse ?. qualified instead, what’s the ?.qualified ?
rokee
12/30/2015, 9:31 AMrokee
12/30/2015, 9:32 AMrokee
12/30/2015, 9:33 AMdmitry.petrov
12/30/2015, 9:35 AM!!
for values that come from Java and used as non-nullablekrtko
12/30/2015, 10:24 AMkrtko
12/30/2015, 10:24 AMkrtko
12/30/2015, 10:25 AMkrtko
12/30/2015, 10:25 AMkrtko
12/30/2015, 10:25 AMmg6maciej
12/30/2015, 10:53 AMclass Person(
private val name: String,
private val surname: String) {
val fullName1 by lazy { "$name $surname" }
val fullName2 = "$name $surname"
val fullName3: String get() = "$name $surname"
}
why would 1 and 2 throw java.lang.IllegalArgumentException: Parameter specified as non-null is null: method kotlin.jvm.internal.Intrinsics.checkParameterIsNotNull
while 3 is working fine?mg6maciej
12/30/2015, 10:55 AMmg6maciej
12/30/2015, 10:56 AMrokee
12/30/2015, 10:56 AM!!
makes my code to be have less readability and make more crashable, I prefer to use ?
. but i’m sad that i can’t use ?
for property of java.dmitry.petrov
12/30/2015, 10:58 AMmodule.itemsType
, right?
How is itemsType
declared?rokee
12/30/2015, 10:58 AMString itemsType;
rokee
12/30/2015, 10:58 AMrokee
12/30/2015, 11:00 AMnull
.rokee
12/30/2015, 11:00 AMrokee
12/30/2015, 11:00 AMdmitry.petrov
12/30/2015, 11:00 AMrokee
12/30/2015, 11:00 AMrokee
12/30/2015, 11:03 AM