summaryrefslogtreecommitdiff
path: root/src/wasm/wasm.cpp
diff options
context:
space:
mode:
authorAlon Zakai (kripken) <alonzakai@gmail.com>2017-07-10 18:01:37 -0700
committerAlon Zakai (kripken) <alonzakai@gmail.com>2017-07-11 11:07:45 -0700
commit45f8fedce6d432bfe24573ae4edb092202ef7bb9 (patch)
treec5d29ea64b1acbf28bb71ceb28b87d917cd6df0b /src/wasm/wasm.cpp
parent90b9b94fdeee3def639006e53be8e282cd7d14f0 (diff)
downloadbinaryen-45f8fedce6d432bfe24573ae4edb092202ef7bb9.tar.gz
binaryen-45f8fedce6d432bfe24573ae4edb092202ef7bb9.tar.bz2
binaryen-45f8fedce6d432bfe24573ae4edb092202ef7bb9.zip
fix Const finalization and use it properly in br finalization in Precompute
Diffstat (limited to 'src/wasm/wasm.cpp')
-rw-r--r--src/wasm/wasm.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/wasm/wasm.cpp b/src/wasm/wasm.cpp
index ec53ab25a..20b075fd1 100644
--- a/src/wasm/wasm.cpp
+++ b/src/wasm/wasm.cpp
@@ -371,6 +371,10 @@ Const* Const::set(Literal value_) {
return this;
}
+void Const::finalize() {
+ type = value.type;
+}
+
bool Unary::isRelational() {
return op == EqZInt32 || op == EqZInt64;
}