mirror of
https://github.com/catseye/SixtyPical.git
synced 2024-11-22 17:32:01 +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
|
? 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.
|
Can't `goto` a routine that outputs or trashes more than the current routine.
|
||||||
|
|
||||||
| routine bar trashes x, y, z, n {
|
| routine bar trashes x, y, z, n {
|
||||||
|
Loading…
Reference in New Issue
Block a user