test for stdlib opcodes
This commit is contained in:
12
internal/inst/table.go
Normal file
12
internal/inst/table.go
Normal file
@@ -0,0 +1,12 @@
|
||||
package inst
|
||||
|
||||
//go:generate avogen -data ../data -output ztable.go godata
|
||||
|
||||
func Lookup(opcode string) (Instruction, bool) {
|
||||
for _, i := range Instructions {
|
||||
if i.Opcode == opcode {
|
||||
return i, true
|
||||
}
|
||||
}
|
||||
return Instruction{}, false
|
||||
}
|
||||
Reference in New Issue
Block a user