summaryrefslogtreecommitdiff
path: root/src/wasm/literal.cpp
diff options
context:
space:
mode:
authorDaniel Wirtz <dcode@dcode.io>2020-08-24 20:13:02 +0200
committerGitHub <noreply@github.com>2020-08-24 11:13:02 -0700
commitfa43b5070b9c46c88d725ceb76f61340324d2ea0 (patch)
tree90852037dd4fc6697b75963eb90a48bfb514d381 /src/wasm/literal.cpp
parentd2e2521e55120465549ddbccc4660ff98e929008 (diff)
downloadbinaryen-fa43b5070b9c46c88d725ceb76f61340324d2ea0.tar.gz
binaryen-fa43b5070b9c46c88d725ceb76f61340324d2ea0.tar.bz2
binaryen-fa43b5070b9c46c88d725ceb76f61340324d2ea0.zip
Add new compound Signature, Struct and Array types (#3012)
Extends the `Type` hash-consing infrastructure to handle type-parameterized and constructed types introduced in the typed function references and GC proposals. This should be a non-functional change since the new types are not used anywhere yet. Recursive type construction and canonicalization is also left as future work. Co-authored-by: Thomas Lively <tlively@google.com>
Diffstat (limited to 'src/wasm/literal.cpp')
-rw-r--r--src/wasm/literal.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/wasm/literal.cpp b/src/wasm/literal.cpp
index 205d65b84..ffb007cf3 100644
--- a/src/wasm/literal.cpp
+++ b/src/wasm/literal.cpp
@@ -1435,8 +1435,7 @@ Literal Literal::shuffleV8x16(const Literal& other,
return Literal(bytes);
}
-template<Type::ValueType Ty, int Lanes>
-static Literal splat(const Literal& val) {
+template<Type::BasicID Ty, int Lanes> static Literal splat(const Literal& val) {
assert(val.type == Ty);
LaneArray<Lanes> lanes;
lanes.fill(val);