ffi 1.21: #jni_call(bool) → CallBooleanMethod (slot 37) — make-green
One-line addition: `.bool => Jni.CallBooleanMethod`. The lazy-cache
+ dispatch from 1.17 handles the rest. JNI's `jboolean` is i8 in the
C ABI but always carries 0 or 1; LLVM's call boundary truncates the
return byte to i1 and the sx-level bool reads the low bit
canonically.
IR snapshot updated: `ret i1 undef` replaced by the full sequence
through vtable slot 37 keyed on `("isShown", "()Z")`.
This commit is contained in:
@@ -1244,6 +1244,7 @@ pub const LLVMEmitter = struct {
|
||||
.s32 => Jni.CallIntMethod,
|
||||
.s64 => Jni.CallLongMethod,
|
||||
.f64 => Jni.CallDoubleMethod,
|
||||
.bool => Jni.CallBooleanMethod,
|
||||
else => {
|
||||
self.mapRef(c.LLVMGetUndef(self.toLLVMType(instruction.ty)));
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user