mp
08/01/2018, 7:34 PMjdiaz
08/04/2018, 7:38 PMjuliocbcotta
08/08/2018, 4:21 AMedwardwongtl
08/08/2018, 5:01 AMelect
08/10/2018, 10:27 AMvpriscan
08/17/2018, 8:40 AMtwisterrob
08/18/2018, 10:43 AMjuliocbcotta
08/21/2018, 8:19 PMRuckus
08/24/2018, 9:17 PMorangy
08/28/2018, 1:45 PMShawn
08/29/2018, 2:41 AMvoddan
08/30/2018, 9:31 AMAregev2
08/30/2018, 6:18 PMAlbert
09/03/2018, 11:54 AMMohamed Ebrahim
09/06/2018, 2:33 AMkarelpeeters
09/06/2018, 11:19 AMoshai
09/06/2018, 8:35 PMelect
09/09/2018, 5:31 AMelect
09/09/2018, 8:40 AMAlbert
09/12/2018, 8:12 AMinline fun <reified T> apply(apply: T) {
on(apply)
}
fun on(apply: Any?) {
throw Exception()
}
fun on(apply: String) {
println("String: $apply")
}
fun on(apply: Int) {
println("Int: $apply")
}
When apply("test")
it will always endup in on(apply: Any?)
. I thought that inline
with reified
was basically a "copy/paste" behavior of that method. So when performing apply("test")
I would expect that after compiling it would look like something like so on("test")
. Clearly I am making a wrong assumption here.
Is it possible to do something like this? Or should I always use a reflection to resolve this at runtime?pga4711
09/12/2018, 9:06 AMpi@rpi3dev1:~ $ cat /proc/sys/kernel/hostname
rpi3dev1
pi@rpi3dev1:~ $ ifconfig
...
inet 192.168.35.6 ...But i can ping that IP-adress from the windows PC.
gabrielfv
09/12/2018, 9:09 PMobject MyObj {
const val MESSAGE = "msg"
}
Getting the bytecode and decompiling, it translates into
// Simplified
public final class MyObj {
@NotNull
public static final String MESSAGE = "msg";
public static final MyObj INSTANCE;
static {
INSTANCE = new MyObj();
}
}
gabrielfv
09/12/2018, 9:12 PMprivate <init>()V
be the private constructor? Why doesn't it show up on the java decompiled version?elect
09/15/2018, 6:18 AMPaul Woitaschek
09/16/2018, 1:20 PMagrosner
09/16/2018, 10:53 PMAlbert
09/17/2018, 9:37 AMIterator
?thomasnield
09/17/2018, 6:02 PMjanvladimirmostert
09/18/2018, 8:40 AMursus
09/19/2018, 6:27 AMursus
09/19/2018, 6:27 AMmaxmello
09/19/2018, 7:45 AMursus
09/19/2018, 2:40 PM