diff options
Diffstat (limited to 'src/wasm/wasm-s-parser.cpp')
-rw-r--r-- | src/wasm/wasm-s-parser.cpp | 9 |
1 files changed, 0 insertions, 9 deletions
diff --git a/src/wasm/wasm-s-parser.cpp b/src/wasm/wasm-s-parser.cpp index 4fdc29a66..2f791609a 100644 --- a/src/wasm/wasm-s-parser.cpp +++ b/src/wasm/wasm-s-parser.cpp @@ -2805,15 +2805,6 @@ Expression* SExpressionWasmBuilder::makeRefCast(Element& s) { if (legacy) { // Legacy polymorphic behavior. nullability = ref->type.getNullability(); - } else if (ref->type.isRef()) { - // Only accept instructions emulating the legacy behavior for now. - if (nullability == NonNullable && ref->type.isNullable()) { - throw ParseException( - "ref.cast on nullable input not yet supported", s.line, s.col); - } else if (nullability == Nullable && ref->type.isNonNullable()) { - throw ParseException( - "ref.cast null on non-nullable input not yet supported", s.line, s.col); - } } auto type = Type(heapType, nullability); return Builder(wasm).makeRefCast(ref, type, RefCast::Safe); |