mirror of
https://github.com/catseye/SixtyPical.git
synced 2024-11-26 14:49:15 +00:00
Add failing test for multiple gotos that are all in tail position.
This commit is contained in:
parent
b1e9df0d45
commit
5f62de11c2
@ -2231,6 +2231,22 @@ Calling the vector does indeed trash the things the vector says it does.
|
||||
| }
|
||||
? IllegalJumpError
|
||||
|
||||
| routine bar trashes x, z, n {
|
||||
| ld x, 200
|
||||
| }
|
||||
|
|
||||
| routine main trashes x, z, n {
|
||||
| ld x, 0
|
||||
| if z {
|
||||
| ld x, 1
|
||||
| goto bar
|
||||
| } else {
|
||||
| ld x, 0
|
||||
| goto bar
|
||||
| }
|
||||
| }
|
||||
= ok
|
||||
|
||||
Can't `goto` a routine that outputs or trashes more than the current routine.
|
||||
|
||||
| routine bar trashes x, y, z, n {
|
||||
|
Loading…
Reference in New Issue
Block a user