diff options
| -rw-r--r-- | compiler/elymasGlobal.ey | 17 | ||||
| -rw-r--r-- | notes | 1 |
2 files changed, 18 insertions, 0 deletions
diff --git a/compiler/elymasGlobal.ey b/compiler/elymasGlobal.ey index 4435518..52f9aae 100644 --- a/compiler/elymasGlobal.ey +++ b/compiler/elymasGlobal.ey @@ -1158,6 +1158,23 @@ :retn ] /ey> defv + # switch parent of current scope to stack top object + # push current scope onto stack + # switch current scope to original parent + # 0 -> new parent + # 0 <- scope just exited + [ + /rbx :popqReg + /rdx :popqReg + 16 /r14 /rax :movqMemDisp8Reg + /rdx 16 /r14 :movqRegMemDisp8 + /r14 :pushqReg + /rax /r14 :movqRegReg + /rbx :pushqReg + + :retn + ] /ey>' defv + # push current scope onto stack # 0 <- current scope [ @@ -46,6 +46,7 @@ v =name -> set current value of name to v, leave modes intact < -> push new scope > -> pop scope, structured data object now on stack < 0 =a 0 =b > -> something which has a and b is on top of stack +< ... parent >' -> push scope with non-local parent (at the end only) 0 1 2 _ -> 0 1 2 2 0 1 2 -0 -> 0 1 2 |
