aboutsummaryrefslogtreecommitdiffstats
path: root/libevmasm/SemanticInformation.cpp
diff options
context:
space:
mode:
authorWei-Ning Huang <w@dexon.org>2018-10-18 11:38:05 +0800
committerJimmy Hu <jimmy.hu@dexon.org>2019-04-13 20:54:32 +0800
commit500ab821044759594eb3db08876b2925b9b3709b (patch)
tree72da52de9a7e22509b210a70e92430beb143bcae /libevmasm/SemanticInformation.cpp
parent0957231a8ed1990baacd67f48c3d3550b5250733 (diff)
downloaddexon-solidity-500ab821044759594eb3db08876b2925b9b3709b.tar.gz
dexon-solidity-500ab821044759594eb3db08876b2925b9b3709b.tar.zst
dexon-solidity-500ab821044759594eb3db08876b2925b9b3709b.zip
Add opcode RAND support
DEXON has a built-in on chain random oracle that allow one to retrieve a random variable. Add `rand` solidity variable is introduced to load the random variable onto the stack.
Diffstat (limited to 'libevmasm/SemanticInformation.cpp')
-rw-r--r--libevmasm/SemanticInformation.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/libevmasm/SemanticInformation.cpp b/libevmasm/SemanticInformation.cpp
index 2a24a27e..b068f6dc 100644
--- a/libevmasm/SemanticInformation.cpp
+++ b/libevmasm/SemanticInformation.cpp
@@ -239,6 +239,7 @@ bool SemanticInformation::invalidInPureFunctions(Instruction _instruction)
case Instruction::BLOCKHASH:
case Instruction::COINBASE:
case Instruction::TIMESTAMP:
+ case Instruction::RAND:
case Instruction::NUMBER:
case Instruction::DIFFICULTY:
case Instruction::GASLIMIT: