aboutsummaryrefslogtreecommitdiffstats
path: root/libsolidity
diff options
context:
space:
mode:
authorAlex Beregszaszi <alex@rtfs.hu>2018-09-28 07:04:40 +0800
committerGitHub <noreply@github.com>2018-09-28 07:04:40 +0800
commitc4b5101b9d8337069c495b95b04a420e2665aa2d (patch)
tree7348765fe7db6c74a8003dc8a972e477fa30fe41 /libsolidity
parentf36dee1067f09e2a6e5ec0dc5996e19e5f36c8bd (diff)
parent8d8c855810ed51d17cab679cd89f7a75410a4258 (diff)
downloaddexon-solidity-c4b5101b9d8337069c495b95b04a420e2665aa2d.tar
dexon-solidity-c4b5101b9d8337069c495b95b04a420e2665aa2d.tar.gz
dexon-solidity-c4b5101b9d8337069c495b95b04a420e2665aa2d.tar.bz2
dexon-solidity-c4b5101b9d8337069c495b95b04a420e2665aa2d.tar.lz
dexon-solidity-c4b5101b9d8337069c495b95b04a420e2665aa2d.tar.xz
dexon-solidity-c4b5101b9d8337069c495b95b04a420e2665aa2d.tar.zst
dexon-solidity-c4b5101b9d8337069c495b95b04a420e2665aa2d.zip
Merge pull request #4676 from jwasinger/extcodehash
Add support for EXTCODEHASH
Diffstat (limited to 'libsolidity')
-rw-r--r--libsolidity/inlineasm/AsmAnalysis.cpp12
1 files changed, 11 insertions, 1 deletions
diff --git a/libsolidity/inlineasm/AsmAnalysis.cpp b/libsolidity/inlineasm/AsmAnalysis.cpp
index 0f2c0f56..947b6d05 100644
--- a/libsolidity/inlineasm/AsmAnalysis.cpp
+++ b/libsolidity/inlineasm/AsmAnalysis.cpp
@@ -568,7 +568,17 @@ void AsmAnalyzer::warnOnInstructions(solidity::Instruction _instr, SourceLocatio
// Similarly we assume bitwise shifting and create2 go together.
solAssert(m_evmVersion.hasBitwiseShifting() == m_evmVersion.hasCreate2(), "");
- if ((
+ if (_instr == solidity::Instruction::EXTCODEHASH)
+ m_errorReporter.warning(
+ _location,
+ "The \"" +
+ boost::to_lower_copy(instructionInfo(_instr).name)
+ + "\" instruction is not supported by the VM version \"" +
+ "" + m_evmVersion.name() +
+ "\" you are currently compiling for. " +
+ "It will be interpreted as an invalid instruction on this VM."
+ );
+ else if ((
_instr == solidity::Instruction::RETURNDATACOPY ||
_instr == solidity::Instruction::RETURNDATASIZE ||
_instr == solidity::Instruction::STATICCALL