From f30d9f6cde023b29409f73aba68f472c06c3b11c Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Wed, 3 Aug 2016 12:12:24 -0700 Subject: loops no longer have an out label and other upstream loop updates --- src/wasm-binary.h | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) (limited to 'src/wasm-binary.h') diff --git a/src/wasm-binary.h b/src/wasm-binary.h index 791a0459b..373465296 100644 --- a/src/wasm-binary.h +++ b/src/wasm-binary.h @@ -875,11 +875,9 @@ public: void visitLoop(Loop *curr) { if (debug) std::cerr << "zz node: Loop" << std::endl; o << int8_t(BinaryConsts::Loop); - breakStack.push_back(curr->out); - breakStack.push_back(curr->in); + breakStack.push_back(curr->name); recursePossibleBlockContents(curr->body); breakStack.pop_back(); - breakStack.pop_back(); o << int8_t(BinaryConsts::End); } @@ -1841,13 +1839,10 @@ public: } void visitLoop(Loop *curr) { if (debug) std::cerr << "zz node: Loop" << std::endl; - curr->out = getNextLabel(); - curr->in = getNextLabel(); - breakStack.push_back(curr->out); - breakStack.push_back(curr->in); + curr->name = getNextLabel(); + breakStack.push_back(curr->name); curr->body = getMaybeBlock(); breakStack.pop_back(); - breakStack.pop_back(); curr->finalize(); } -- cgit v1.2.3