diff options
author | chriseth <c@ethdev.com> | 2015-12-10 00:53:15 +0800 |
---|---|---|
committer | chriseth <c@ethdev.com> | 2015-12-10 00:57:34 +0800 |
commit | 39f57a9c718159448b0f9df199c3a0a019f32ca2 (patch) | |
tree | 27b593c6539cb8711f2623f3a0d12347bc793183 /solc/CommandLineInterface.cpp | |
parent | 15a1468c3fcf520b9c8f0af22159ea729cf9f085 (diff) | |
download | dexon-solidity-39f57a9c718159448b0f9df199c3a0a019f32ca2.tar.gz dexon-solidity-39f57a9c718159448b0f9df199c3a0a019f32ca2.tar.zst dexon-solidity-39f57a9c718159448b0f9df199c3a0a019f32ca2.zip |
Fix: Segfaults connected to paramater types.
parameterTypes does not return by const reference anymore.
Diffstat (limited to 'solc/CommandLineInterface.cpp')
-rw-r--r-- | solc/CommandLineInterface.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/solc/CommandLineInterface.cpp b/solc/CommandLineInterface.cpp index 376196e1..fe760fdf 100644 --- a/solc/CommandLineInterface.cpp +++ b/solc/CommandLineInterface.cpp @@ -278,9 +278,9 @@ void CommandLineInterface::handleGasEstimation(string const& _contract) gas = GasEstimator::functionalEstimation(*items, entry, *it); FunctionType type(*it); cout << " " << it->name() << "("; - auto end = type.parameterTypes().end(); - for (auto it = type.parameterTypes().begin(); it != end; ++it) - cout << (*it)->toString() << (it + 1 == end ? "" : ","); + auto paramTypes = type.parameterTypes(); + for (auto it = paramTypes.begin(); it != paramTypes.end(); ++it) + cout << (*it)->toString() << (it + 1 == paramTypes.end() ? "" : ","); cout << "):\t" << gas << endl; } } |