summaryrefslogtreecommitdiff
path: root/src/wasm/literal.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/wasm/literal.cpp')
-rw-r--r--src/wasm/literal.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/wasm/literal.cpp b/src/wasm/literal.cpp
index 20b6b7234..a49fa1b62 100644
--- a/src/wasm/literal.cpp
+++ b/src/wasm/literal.cpp
@@ -445,7 +445,8 @@ bool Literal::operator==(const Literal& other) const {
if (type.isData()) {
return gcData == other.gcData;
}
- if (type.getHeapType() == HeapType::i31) {
+ assert(type.getHeapType().isBasic());
+ if (type.getHeapType().getBasic(Unshared) == HeapType::i31) {
return i32 == other.i32;
}
WASM_UNREACHABLE("unexpected type");