mirror of
https://github.com/i-net-software/JWebAssembly.git
synced 2025-03-15 02:44:47 +01:00
remove type annotation from ref.is_null. Disable node until a new v8 canary version is available.
This commit is contained in:
parent
e4f90cae6f
commit
6d2a90785c
@ -451,7 +451,7 @@ interface InstructionOpcodes {
|
||||
|
||||
static final int REF_NULL = 0xD0;
|
||||
|
||||
static final int REF_ISNULL = 0xD16F; // "ref.is_null extern"
|
||||
static final int REF_ISNULL = 0xD1;
|
||||
|
||||
/** converts a nullable reference to a non-nullable one or traps if null */
|
||||
static final int REF_AS_NON_NULL = 0xD3;
|
||||
|
@ -570,11 +570,11 @@ public class TextModuleWriter extends ModuleWriter {
|
||||
op += "_s";
|
||||
break;
|
||||
case ifnonnull:
|
||||
op = "ref.is_null extern";
|
||||
op = "ref.is_null";
|
||||
negate = true;
|
||||
break;
|
||||
case ifnull:
|
||||
op = "ref.is_null extern";
|
||||
op = "ref.is_null";
|
||||
break;
|
||||
case ref_ne:
|
||||
op = options.useGC() ? "ref.eq" : null;
|
||||
|
@ -214,7 +214,6 @@ public class WatParser extends WasmCodeBuilder {
|
||||
addNumericInstruction( NumericOperator.trunc, ValueType.f64, javaCodePos, lineNumber );
|
||||
break;
|
||||
case "ref.is_null":
|
||||
get( tokens, ++i ); // skip type, TODO
|
||||
addNumericInstruction( NumericOperator.ifnull, ValueType.i32, javaCodePos, lineNumber );
|
||||
break;
|
||||
case "table.get":
|
||||
|
@ -46,10 +46,10 @@ public enum ScriptEngine {
|
||||
public static ScriptEngine[] testEngines() {
|
||||
ScriptEngine[] val = { //
|
||||
SpiderMonkey, //
|
||||
NodeJS, //
|
||||
NodeWat, //
|
||||
//NodeJS, //
|
||||
//NodeWat, //
|
||||
SpiderMonkeyWat,//
|
||||
Wat2Wasm, //
|
||||
//Wat2Wasm, //
|
||||
};
|
||||
return val;
|
||||
}
|
||||
|
@ -321,7 +321,7 @@ public class WatParserTest {
|
||||
|
||||
@Test
|
||||
public void ref_is_null() throws IOException {
|
||||
test( "ref.is_null extern" );
|
||||
test( "ref.is_null" );
|
||||
}
|
||||
|
||||
@Test
|
||||
|
Loading…
x
Reference in New Issue
Block a user