summaryrefslogtreecommitdiff
path: root/src/wasm.h
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2016-02-08 10:54:19 -0800
committerAlon Zakai <alonzakai@gmail.com>2016-02-08 11:40:37 -0800
commit79d405b82b648cc406a12ce7164a4ef31279c67c (patch)
tree2d3504981d4a10e0c1563232dc09103722e5e1b7 /src/wasm.h
parent271504de91e3f396251041f94c0f29094af92207 (diff)
downloadbinaryen-79d405b82b648cc406a12ce7164a4ef31279c67c.tar.gz
binaryen-79d405b82b648cc406a12ce7164a4ef31279c67c.tar.bz2
binaryen-79d405b82b648cc406a12ce7164a4ef31279c67c.zip
update spec tests and shift to putting the br_if condition at the end, as was just changed to in the spec
Diffstat (limited to 'src/wasm.h')
-rw-r--r--src/wasm.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/wasm.h b/src/wasm.h
index 893c777c4..20a7b34ef 100644
--- a/src/wasm.h
+++ b/src/wasm.h
@@ -511,10 +511,8 @@ public:
std::ostream& doPrint(std::ostream &o, unsigned indent) {
if (condition) {
- printOpening(o, "br_if");
+ printOpening(o, "br_if ") << name;
incIndent(o, indent);
- printFullLine(o, indent, condition);
- doIndent(o, indent) << name << '\n';
} else {
printOpening(o, "br ") << name;
if (!value || value->is<Nop>()) {
@@ -525,6 +523,9 @@ public:
incIndent(o, indent);
}
if (value && !value->is<Nop>()) printFullLine(o, indent, value);
+ if (condition) {
+ printFullLine(o, indent, condition);
+ }
return decIndent(o, indent);
}
};