diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/wasm/wasm-type.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/wasm/wasm-type.cpp b/src/wasm/wasm-type.cpp index 43b381a1b..b2cde6050 100644 --- a/src/wasm/wasm-type.cpp +++ b/src/wasm/wasm-type.cpp @@ -1746,12 +1746,11 @@ bool SubTyper::isSubType(HeapType a, HeapType b) { if (b.isBasic()) { switch (b.getBasic()) { case HeapType::ext: - return a == HeapType::noext; + return a.getBottom() == HeapType::noext; case HeapType::func: - return a == HeapType::nofunc || a.isSignature(); + return a.getBottom() == HeapType::nofunc; case HeapType::any: - return a == HeapType::eq || a == HeapType::i31 || a == HeapType::data || - a == HeapType::none || a.isData(); + return a.getBottom() == HeapType::none; case HeapType::eq: return a == HeapType::i31 || a == HeapType::data || a == HeapType::none || a.isData(); |