masted
03/12/2016, 10:41 PMmasted
03/12/2016, 10:41 PMsomoni
03/12/2016, 10:43 PMsomoni
03/12/2016, 10:43 PMsomoni
03/12/2016, 10:43 PMsomoni
03/12/2016, 10:44 PMsomoni
03/12/2016, 10:50 PMsomoni
03/12/2016, 10:52 PMmasted
03/12/2016, 10:56 PMmichaelrocks
03/13/2016, 1:51 PMinternal
.orangy
internal
in Kotlin (public
in JVM world) and used from inline functions.eshioji
03/13/2016, 2:17 PMmichaelrocks
03/13/2016, 2:25 PMinternal
works.eshioji
03/13/2016, 2:39 PMeshioji
03/13/2016, 2:43 PMprivate
fields being accessed by inline
functions. Though I guess it would be rather surprising if some of the private
fields are actually private
and some of them are mangled...eshioji
03/13/2016, 2:43 PMkirillrakhman
03/13/2016, 3:04 PMsimonorono
03/13/2016, 3:11 PMimport org.objectweb.asm.ClassWriter
import org.objectweb.asm.Opcodes
import sron.grpc.compiler.internal.GrpParser
class Generation : Phase(), Opcodes {
private val cw = ClassWriter(0)
override fun enterInit(ctx: GrpParser.InitContext) {
super.enterInit(ctx)
cw.visit(V1_8 /* Other parameters */)
}
override fun exitInit(ctx: GrpParser.InitContext) {
super.exitInit(ctx)
}
}
However, that V1_8
it's defined here in the Opcodes interface:
public interface Opcodes {
// ASM API versions
int ASM4 = 4 << 16 | 0 << 8 | 0;
int ASM5 = 5 << 16 | 0 << 8 | 0;
// versions
int V1_1 = 3 << 16 | 45;
int V1_2 = 0 << 16 | 46;
int V1_3 = 0 << 16 | 47;
int V1_4 = 0 << 16 | 48;
int V1_5 = 0 << 16 | 49;
int V1_6 = 0 << 16 | 50;
int V1_7 = 0 << 16 | 51;
int V1_8 = 0 << 16 | 52;
...
Nevertheless, I can not access it without prefixing with Opcodes
like Opcodes.V1_8
. Is this normal behavior?simonorono
03/13/2016, 3:28 PMOpcodes
prefixkirillrakhman
03/13/2016, 4:23 PMsomoni
03/13/2016, 4:29 PMvmironov
03/13/2016, 4:33 PMvmironov
03/13/2016, 4:51 PMvmironov
03/13/2016, 4:52 PMeshioji
03/13/2016, 5:19 PMeshioji
03/13/2016, 5:19 PMeshioji
03/13/2016, 5:19 PMeshioji
03/13/2016, 5:20 PMeshioji
03/13/2016, 5:22 PMo.put
to o.addTo
it succeedseshioji
03/13/2016, 5:23 PMInt2DoubleOpenHashMap
has both Double put(final Integer ok, final Double ov)
and double put(final int k, final double v)
defined, while addTo has only one with primitive types