Full test (which fails)
This commit is contained in:
@@ -41,12 +41,5 @@ func NewInstructionsFromByteCode(byteCode []byte) ([]*Instruction, error) {
|
||||
instrs = append(instrs, instr)
|
||||
}
|
||||
|
||||
if len(instrs) == 0 || instrs[len(instrs)-1].OpCode != OpReturn {
|
||||
// Add implicit return at the end of each function
|
||||
instrs = append(instrs, &Instruction{
|
||||
OpCode: OpReturn,
|
||||
})
|
||||
}
|
||||
|
||||
return instrs, nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user