diff options
author | Alex Beregszaszi <alex@rtfs.hu> | 2017-05-17 18:21:37 +0800 |
---|---|---|
committer | Alex Beregszaszi <alex@rtfs.hu> | 2017-05-26 10:20:10 +0800 |
commit | 66eab1caf63f9221a279abf71de953524fe9c2ad (patch) | |
tree | deec1c6b67f411d4a1efdee9400640e5c61a989e /libsolidity/inlineasm/AsmPrinter.cpp | |
parent | b5080860d5f2d141b8fccceaa635378a86c996a8 (diff) | |
download | dexon-solidity-66eab1caf63f9221a279abf71de953524fe9c2ad.tar.gz dexon-solidity-66eab1caf63f9221a279abf71de953524fe9c2ad.tar.zst dexon-solidity-66eab1caf63f9221a279abf71de953524fe9c2ad.zip |
Change switch case string to Literal
Diffstat (limited to 'libsolidity/inlineasm/AsmPrinter.cpp')
-rw-r--r-- | libsolidity/inlineasm/AsmPrinter.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libsolidity/inlineasm/AsmPrinter.cpp b/libsolidity/inlineasm/AsmPrinter.cpp index 92200f84..1ef9d071 100644 --- a/libsolidity/inlineasm/AsmPrinter.cpp +++ b/libsolidity/inlineasm/AsmPrinter.cpp @@ -172,10 +172,10 @@ string AsmPrinter::operator()(Switch const& _switch) string out = "switch " + boost::apply_visitor(*this, *_switch.expression); for (auto const& _case: _switch.cases) { - if (_case.name.empty()) + if (!_case.value) out += "\ndefault: "; else - out += "\ncase " + _case.name + ": "; + out += "\ncase " + (*this)(*_case.value) + ": "; out += (*this)(_case.body); } return out; |