A2osX/BIN/CC.S.SCOPE.txt

59 lines
874 B
Plaintext
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

NEW
AUTO 3,1
*--------------------------------------
SCOPE.New ldy ScopeIdx
cpy #CC.ScopeIDs+SCOPE.MAX*2
bcs .9
iny
iny
sty ScopeIdx
>INCW.G CC.ScopeID
>LDA.G CC.ScopeID
ldy ScopeIdx
sta (pData),y
>LDA.G CC.ScopeID+1
ldy ScopeIdx
iny
sta (pData),y
dec bLocalScope
clc
rts
.9 lda #E.OOH
sec
.99 rts
*--------------------------------------
SCOPE.Close ldy ScopeIdx
cpy #CC.ScopeIDs
beq *
dey
dey
sty ScopeIdx
inc bLocalScope
rts
*--------------------------------------
SCOPE.Push ldy ScopeIdx
SCOPE.PushY iny
lda (pData),y
>PUSHA
dey
lda (pData),y
>PUSHA
rts
*--------------------------------------
MAN
SAVE usr/src/bin/cc.s.scope
LOAD usr/src/bin/cc.s
ASM