aboutsummaryrefslogtreecommitdiff
path: root/core/vm/jump_table.go
diff options
context:
space:
mode:
authorAaron Buchwald <[email protected]>2020-11-23 20:46:35 -0500
committerAaron Buchwald <[email protected]>2020-12-15 10:46:26 -0500
commit368844ad2a28ec07848e3c0169cf2b83b579a2e8 (patch)
tree0b3956351add28aed944824eb45ffb2723809dba /core/vm/jump_table.go
parent2d0a37c6490dc9a4ec36ee4ebbed01c790f0426a (diff)
Add native asset precompiled contracts for apricot release
Diffstat (limited to 'core/vm/jump_table.go')
-rw-r--r--core/vm/jump_table.go11
1 files changed, 11 insertions, 0 deletions
diff --git a/core/vm/jump_table.go b/core/vm/jump_table.go
index 9b538d4..fc12f93 100644
--- a/core/vm/jump_table.go
+++ b/core/vm/jump_table.go
@@ -49,6 +49,7 @@ type operation struct {
}
var (
+ apricotInstructionSet = newApricotInstructionSet()
frontierInstructionSet = newFrontierInstructionSet()
homesteadInstructionSet = newHomesteadInstructionSet()
tangerineWhistleInstructionSet = newTangerineWhistleInstructionSet()
@@ -1043,3 +1044,13 @@ func newFrontierInstructionSet() JumpTable {
},
}
}
+
+// newApricotInstructionSet returns a new instruction set
+// compatible with the Apricot release, which deprecates
+// added instructions: CALLEX and BALANCEMC
+func newApricotInstructionSet() JumpTable {
+ instructionSet := newFrontierInstructionSet()
+ instructionSet[CALLEX] = nil
+ instructionSet[BALANCEMC] = nil
+ return instructionSet
+}