aboutsummaryrefslogtreecommitdiffstats
path: root/libsolidity/inlineasm/AsmParser.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'libsolidity/inlineasm/AsmParser.cpp')
-rw-r--r--libsolidity/inlineasm/AsmParser.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/libsolidity/inlineasm/AsmParser.cpp b/libsolidity/inlineasm/AsmParser.cpp
index 5d439b2f..779646b8 100644
--- a/libsolidity/inlineasm/AsmParser.cpp
+++ b/libsolidity/inlineasm/AsmParser.cpp
@@ -148,6 +148,10 @@ assembly::Statement Parser::parseStatement()
break;
expectToken(Token::Comma);
}
+ // Push an empty string to signify that there were brackets, like in
+ // "name[]:", which just resets the stack height to the height of the local variables.
+ if (label.stackInfo.empty())
+ label.stackInfo.push_back("");
expectToken(Token::RBrack);
label.location.end = endPosition();
expectToken(Token::Colon);