summaryrefslogtreecommitdiff
path: root/src/wasm/wasm-validator.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/wasm/wasm-validator.cpp')
-rw-r--r--src/wasm/wasm-validator.cpp18
1 files changed, 10 insertions, 8 deletions
diff --git a/src/wasm/wasm-validator.cpp b/src/wasm/wasm-validator.cpp
index 9732f54a9..eb2f949b2 100644
--- a/src/wasm/wasm-validator.cpp
+++ b/src/wasm/wasm-validator.cpp
@@ -2222,10 +2222,11 @@ void FunctionValidator::visitRefAs(RefAs* curr) {
if (curr->type == Type::unreachable) {
return;
}
- shouldBeSubType(curr->value->type,
- Type(HeapType::ext, Nullable),
- curr->value,
- "any.convert_extern value should be an externref");
+ shouldBeSubTypeIgnoringShared(
+ curr->value->type,
+ Type(HeapType::ext, Nullable),
+ curr->value,
+ "any.convert_extern value should be an externref");
break;
}
case ExternConvertAny: {
@@ -2235,10 +2236,11 @@ void FunctionValidator::visitRefAs(RefAs* curr) {
if (curr->type == Type::unreachable) {
return;
}
- shouldBeSubType(curr->value->type,
- Type(HeapType::any, Nullable),
- curr->value,
- "extern.convert_any value should be an anyref");
+ shouldBeSubTypeIgnoringShared(
+ curr->value->type,
+ Type(HeapType::any, Nullable),
+ curr->value,
+ "extern.convert_any value should be an anyref");
break;
}
}