diff options
Diffstat (limited to 'src/wasm-type.h')
-rw-r--r-- | src/wasm-type.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/wasm-type.h b/src/wasm-type.h index 1f6c5a7de..2362a95aa 100644 --- a/src/wasm-type.h +++ b/src/wasm-type.h @@ -576,6 +576,13 @@ struct TypeBuilder { void setHeapType(size_t i, Struct&& struct_); void setHeapType(size_t i, Array array); + // This is an ugly hack around the fact that temp heap types initialized with + // BasicHeapTypes are not themselves considered basic, so `HeapType::isBasic` + // and `HeapType::getBasic` do not work as expected with them. Call these + // methods instead. + bool isBasic(size_t i); + HeapType::BasicHeapType getBasic(size_t i); + // Gets the temporary HeapType at index `i`. This HeapType should only be used // to construct temporary Types using the methods below. HeapType getTempHeapType(size_t i); |