Skip to content

Commit

Permalink
Return passed in struct.
Browse files Browse the repository at this point in the history
  • Loading branch information
tristanmorgan committed Aug 5, 2024
1 parent 164bca5 commit 66772ef
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions parser/tokenise.go
Original file line number Diff line number Diff line change
Expand Up @@ -139,15 +139,15 @@ func reduceInst(inst Instruction) (bool, Instruction) {
case opAddDp:
return true, Instruction{opSkip, inst.operand}
case opSkip:
return true, Instruction{opSkip, inst.operand}
return true, inst
case opAddVal:
return true, Instruction{opSetVal, 0}
case opSetVal:
return true, Instruction{opSetVal, 0}
return true, inst
case opMove:
return true, Instruction{opMove, inst.operand}
return true, inst
case opMovN:
return true, Instruction{opMovN, inst.operand}
return true, inst
default:
return false, Instruction{opNoop, 0}
}
Expand Down

0 comments on commit 66772ef

Please sign in to comment.