2018-01-10 16:34:57 +00:00
|
|
|
|
NEW
|
2017-03-29 15:48:15 +00:00
|
|
|
|
PREFIX /A2OSX.BUILD
|
2018-01-10 16:34:57 +00:00
|
|
|
|
AUTO 4,1
|
2015-10-04 20:55:51 +00:00
|
|
|
|
*---------------------------------------
|
2018-03-23 15:57:35 +00:00
|
|
|
|
* Global Symbol Record: (6+ bytes)
|
|
|
|
|
* 0 : Len
|
2018-01-19 16:21:31 +00:00
|
|
|
|
* 1 : Flags:
|
|
|
|
|
* b7=0=pending,1=resolved
|
|
|
|
|
* b6=R/W (.SE)
|
2018-03-22 16:45:23 +00:00
|
|
|
|
* b2,b1,b0 : Size (in bytes)
|
2018-01-19 16:21:31 +00:00
|
|
|
|
* 2-5 : 32 bits Value
|
2018-03-23 15:57:35 +00:00
|
|
|
|
* 6+ : Local Symbols.....
|
2015-11-13 16:25:31 +00:00
|
|
|
|
*---------------------------------------
|
2018-04-06 15:10:02 +00:00
|
|
|
|
* Local Symbol Record: (5 bytes)
|
|
|
|
|
* 0 : Local ID (1->255)
|
|
|
|
|
* 1-4 : 32 bits Value (PC)
|
|
|
|
|
*---------------------------------------
|
2018-03-28 15:23:32 +00:00
|
|
|
|
SYM.Init >SYSCALL SListNew
|
|
|
|
|
bcs .9
|
2018-01-22 16:52:04 +00:00
|
|
|
|
|
2018-03-28 15:23:32 +00:00
|
|
|
|
>STA.G SYM.hGlobalList
|
|
|
|
|
|
|
|
|
|
>LDYAI 256
|
2018-07-20 11:51:08 +00:00
|
|
|
|
>SYSCALL getmem
|
2018-03-28 15:23:32 +00:00
|
|
|
|
bcs .9
|
|
|
|
|
|
|
|
|
|
>STYA ZPNameBuf
|
|
|
|
|
txa
|
|
|
|
|
>STA.G SYM.hNameBuf
|
|
|
|
|
|
|
|
|
|
>LDYAI 256
|
2018-07-20 11:51:08 +00:00
|
|
|
|
>SYSCALL getmem
|
2018-03-28 15:23:32 +00:00
|
|
|
|
bcs .9
|
|
|
|
|
|
|
|
|
|
>STYA ZPGlobalBuf
|
|
|
|
|
txa
|
|
|
|
|
>STA.G SYM.hGlobalBuf
|
|
|
|
|
|
|
|
|
|
>LDYAI 256
|
2018-07-20 11:51:08 +00:00
|
|
|
|
>SYSCALL getmem
|
2018-03-28 15:23:32 +00:00
|
|
|
|
bcs .9
|
|
|
|
|
|
|
|
|
|
>STYA ZPLookupBuf
|
|
|
|
|
txa
|
|
|
|
|
>STA.G SYM.hLookupBuf
|
|
|
|
|
|
|
|
|
|
.9 rts
|
2018-01-19 16:21:31 +00:00
|
|
|
|
*---------------------------------------
|
2018-03-28 15:23:32 +00:00
|
|
|
|
SYM.Reset lda #0
|
|
|
|
|
sta (ZPGlobalBuf)
|
|
|
|
|
rts
|
2018-03-22 16:45:23 +00:00
|
|
|
|
*---------------------------------------
|
2018-03-28 15:23:32 +00:00
|
|
|
|
SYM.Quit >LDA.G SYM.hLookupBuf
|
|
|
|
|
beq .1
|
|
|
|
|
|
2018-07-18 15:30:42 +00:00
|
|
|
|
>SYSCALL FreeMem
|
2018-03-28 15:23:32 +00:00
|
|
|
|
|
|
|
|
|
.1 >LDA.G SYM.hNameBuf
|
|
|
|
|
beq .2
|
|
|
|
|
|
2018-07-18 15:30:42 +00:00
|
|
|
|
>SYSCALL FreeMem
|
2018-03-28 15:23:32 +00:00
|
|
|
|
|
|
|
|
|
.2 >LDA.G SYM.hGlobalBuf
|
|
|
|
|
beq .3
|
|
|
|
|
|
2018-07-18 15:30:42 +00:00
|
|
|
|
>SYSCALL FreeMem
|
2018-03-28 15:23:32 +00:00
|
|
|
|
.3 >LDA.G SYM.hGlobalList
|
|
|
|
|
beq .8
|
2018-07-24 16:00:24 +00:00
|
|
|
|
>SYSCALL SListFree
|
2018-03-28 15:23:32 +00:00
|
|
|
|
|
|
|
|
|
.8 clc
|
|
|
|
|
rts
|
2015-10-30 16:34:59 +00:00
|
|
|
|
*---------------------------------------
|
2018-03-28 15:23:32 +00:00
|
|
|
|
SYM.Dump stz ZPLinePtr
|
|
|
|
|
stz ZPLinePtr+1
|
2018-01-26 07:04:29 +00:00
|
|
|
|
|
2018-03-28 15:23:32 +00:00
|
|
|
|
>LDA.G ASM.LI.ON
|
|
|
|
|
bpl .1
|
|
|
|
|
|
|
|
|
|
>LDYA L.MSG.SYMBOLS
|
2018-06-21 15:12:10 +00:00
|
|
|
|
>SYSCALL printf
|
2018-01-29 16:48:07 +00:00
|
|
|
|
|
2018-03-28 15:23:32 +00:00
|
|
|
|
.1 >PUSHB.G SYM.hGlobalList
|
|
|
|
|
>PUSHW ZPLinePtr
|
|
|
|
|
>PUSHW ZPGlobalBuf
|
2018-03-30 15:21:42 +00:00
|
|
|
|
>PUSHW ZPNameBuf
|
2018-03-28 15:23:32 +00:00
|
|
|
|
>SYSCALL SListGetByID
|
2018-03-30 15:21:42 +00:00
|
|
|
|
bcc .10
|
2018-03-28 15:23:32 +00:00
|
|
|
|
|
2018-03-30 15:21:42 +00:00
|
|
|
|
clc
|
|
|
|
|
rts
|
|
|
|
|
|
|
|
|
|
.10 stx ZPLinePtr Save Next ID
|
2018-03-28 15:23:32 +00:00
|
|
|
|
sty ZPLinePtr+1
|
|
|
|
|
|
|
|
|
|
>LDA.G ASM.LI.ON
|
|
|
|
|
bpl .1
|
|
|
|
|
|
|
|
|
|
ldy #SYMG.F Get Symbol Size
|
2018-03-30 15:21:42 +00:00
|
|
|
|
lda (ZPGlobalBuf),y
|
2018-03-28 15:23:32 +00:00
|
|
|
|
and #SYMG.F.SIZE
|
2018-03-30 15:21:42 +00:00
|
|
|
|
|
|
|
|
|
tax
|
2018-03-28 15:23:32 +00:00
|
|
|
|
beq .3
|
2018-03-16 16:33:11 +00:00
|
|
|
|
|
2018-03-30 15:21:42 +00:00
|
|
|
|
asl
|
2018-03-28 15:23:32 +00:00
|
|
|
|
pha
|
2018-03-30 15:21:42 +00:00
|
|
|
|
|
|
|
|
|
.2 iny
|
|
|
|
|
lda (ZPGlobalBuf),y
|
2018-03-28 15:23:32 +00:00
|
|
|
|
>PUSHA
|
|
|
|
|
dex
|
|
|
|
|
bne .2
|
|
|
|
|
|
2018-03-30 15:21:42 +00:00
|
|
|
|
plx
|
2018-03-16 16:33:11 +00:00
|
|
|
|
|
2018-03-30 15:21:42 +00:00
|
|
|
|
.3 ldy L.MSG.EQU0,x
|
2018-03-28 15:23:32 +00:00
|
|
|
|
lda L.MSG.EQU0+1,x
|
2018-06-21 15:12:10 +00:00
|
|
|
|
>SYSCALL printf
|
2018-01-25 16:13:28 +00:00
|
|
|
|
|
2018-03-30 15:21:42 +00:00
|
|
|
|
>PUSHW ZPNameBuf Label (PString)
|
2018-03-28 15:23:32 +00:00
|
|
|
|
|
2018-03-30 15:21:42 +00:00
|
|
|
|
>LDYA L.MSG.PSTR
|
2018-06-21 15:12:10 +00:00
|
|
|
|
>SYSCALL printf
|
2018-03-28 15:23:32 +00:00
|
|
|
|
bcs .9
|
2018-04-06 15:10:02 +00:00
|
|
|
|
ldy #SYMG.SIZE
|
2018-03-30 15:21:42 +00:00
|
|
|
|
|
|
|
|
|
.4 tya
|
2018-03-28 15:23:32 +00:00
|
|
|
|
|
2018-03-30 15:21:42 +00:00
|
|
|
|
cmp (ZPGlobalBuf)
|
|
|
|
|
beq .7 No Local Symbol
|
2018-03-28 15:23:32 +00:00
|
|
|
|
|
2018-03-30 15:21:42 +00:00
|
|
|
|
iny
|
|
|
|
|
lda (ZPGlobalBuf),y Get ID
|
|
|
|
|
pha
|
2018-03-28 15:23:32 +00:00
|
|
|
|
|
2018-03-30 15:21:42 +00:00
|
|
|
|
ldx #4
|
2018-03-28 15:23:32 +00:00
|
|
|
|
|
2018-03-30 15:21:42 +00:00
|
|
|
|
.5 iny
|
|
|
|
|
lda (ZPGlobalBuf),y
|
|
|
|
|
>PUSHA
|
|
|
|
|
dex
|
|
|
|
|
bne .5
|
|
|
|
|
|
|
|
|
|
pla
|
|
|
|
|
>PUSHA
|
|
|
|
|
phy
|
2018-04-06 15:10:02 +00:00
|
|
|
|
>LDYA L.MSG.LSYMBOL
|
2018-06-21 15:12:10 +00:00
|
|
|
|
>SYSCALL printf
|
2018-03-30 15:21:42 +00:00
|
|
|
|
ply
|
|
|
|
|
bne .4
|
|
|
|
|
|
|
|
|
|
.7 >LDYA L.MSG.CRLF
|
2018-06-21 15:12:10 +00:00
|
|
|
|
>SYSCALL printf
|
2018-03-28 15:23:32 +00:00
|
|
|
|
jmp .1
|
|
|
|
|
rts
|
|
|
|
|
|
|
|
|
|
.8 clc
|
|
|
|
|
.9 rts
|
2018-01-19 16:21:31 +00:00
|
|
|
|
*---------------------------------------
|
2018-03-28 15:23:32 +00:00
|
|
|
|
SYM.NewOrGetGlobal
|
|
|
|
|
>LDA.G ASM.PASS
|
|
|
|
|
bne SYM.GetGlobal Pass #2: should be already defined...
|
2018-03-23 15:57:35 +00:00
|
|
|
|
|
2018-03-28 15:23:32 +00:00
|
|
|
|
SYM.NewGlobal jsr SYM.LookupGlobal Pass #1; try to add global...
|
|
|
|
|
bcc .9 Already Defined
|
|
|
|
|
|
|
|
|
|
jsr SYM.GetName
|
|
|
|
|
bcs .99
|
|
|
|
|
|
|
|
|
|
jsr SYM.PC2Global A=PC Size
|
2018-01-22 16:52:04 +00:00
|
|
|
|
|
2018-04-06 15:10:02 +00:00
|
|
|
|
lda #SYMG.SIZE
|
2018-03-28 15:23:32 +00:00
|
|
|
|
sta (ZPGlobalBuf)
|
|
|
|
|
clc
|
|
|
|
|
rts
|
|
|
|
|
|
|
|
|
|
.9 lda #ERR.SYMBOL.REDEF
|
|
|
|
|
sec
|
|
|
|
|
.99 rts
|
2018-03-23 15:57:35 +00:00
|
|
|
|
*---------------------------------------
|
2018-03-28 15:23:32 +00:00
|
|
|
|
SYM.GetGlobal >PUSHB.G SYM.hGlobalList
|
|
|
|
|
>PUSHW ZPLinePtr
|
|
|
|
|
>PUSHW ZPGlobalBuf
|
|
|
|
|
>SYSCALL SListLookup
|
2018-01-22 16:52:04 +00:00
|
|
|
|
|
2018-03-28 15:23:32 +00:00
|
|
|
|
bcs .9
|
|
|
|
|
|
|
|
|
|
adc ZPLinePtr
|
|
|
|
|
sta ZPLinePtr
|
|
|
|
|
bcc .1
|
|
|
|
|
|
|
|
|
|
inc ZPLinePtr+1
|
|
|
|
|
clc
|
|
|
|
|
|
|
|
|
|
.1 tya
|
|
|
|
|
>STA.G SYM.GlobalID+1
|
|
|
|
|
txa
|
|
|
|
|
>STA.G SYM.GlobalID
|
|
|
|
|
rts
|
|
|
|
|
|
|
|
|
|
.9 lda #ERR.UNDEF.SYMBOL
|
|
|
|
|
sec
|
|
|
|
|
rts
|
2018-01-22 07:34:59 +00:00
|
|
|
|
*---------------------------------------
|
2018-03-28 15:23:32 +00:00
|
|
|
|
SYM.LookupGlobal
|
|
|
|
|
>PUSHB.G SYM.hGlobalList
|
|
|
|
|
>PUSHW ZPLinePtr
|
|
|
|
|
>PUSHW ZPLookupBuf
|
|
|
|
|
>SYSCALL SListLookup
|
|
|
|
|
bcs .9
|
|
|
|
|
|
|
|
|
|
adc ZPLinePtr
|
|
|
|
|
sta ZPLinePtr
|
|
|
|
|
bcc .8
|
|
|
|
|
|
|
|
|
|
inc ZPLinePtr+1
|
2018-04-06 15:10:02 +00:00
|
|
|
|
clc
|
2018-03-23 15:57:35 +00:00
|
|
|
|
.8
|
2018-03-28 15:23:32 +00:00
|
|
|
|
.9 rts
|
|
|
|
|
*---------------------------------------
|
|
|
|
|
SYM.FlushGlobal lda (ZPGlobalBuf)
|
|
|
|
|
beq .8
|
|
|
|
|
|
|
|
|
|
>PUSHB.G SYM.hGlobalList
|
|
|
|
|
|
|
|
|
|
>LDA.G ASM.PASS
|
|
|
|
|
bne .2
|
|
|
|
|
|
|
|
|
|
>PUSHW ZPNameBuf
|
|
|
|
|
>PUSHW ZPGlobalBuf
|
|
|
|
|
>SYSCALL SListAdd
|
2018-04-06 15:10:02 +00:00
|
|
|
|
bra .3
|
2018-03-28 15:23:32 +00:00
|
|
|
|
|
|
|
|
|
.2 >PUSHW.G SYM.GlobalID
|
|
|
|
|
>PUSHW ZPGlobalBuf
|
|
|
|
|
>SYSCALL SListUpdateByID
|
2018-04-06 15:10:02 +00:00
|
|
|
|
|
|
|
|
|
.3 bcs .9
|
|
|
|
|
lda #0
|
|
|
|
|
sta (ZPGlobalBuf)
|
2018-03-28 15:23:32 +00:00
|
|
|
|
rts
|
|
|
|
|
|
|
|
|
|
.8 clc
|
2018-04-06 15:10:02 +00:00
|
|
|
|
.9 rts
|
2018-03-28 15:23:32 +00:00
|
|
|
|
*---------------------------------------
|
|
|
|
|
SYM.GetName jsr SRC.GetChar
|
|
|
|
|
bcs .9
|
|
|
|
|
|
|
|
|
|
ldy #0
|
|
|
|
|
|
|
|
|
|
.1 jsr SRC.IsLetterOrDigit
|
|
|
|
|
bcc .2
|
|
|
|
|
cmp #'.'
|
|
|
|
|
beq .2
|
|
|
|
|
cmp #'_'
|
|
|
|
|
bne .8
|
|
|
|
|
|
|
|
|
|
.2 sta (ZPNameBuf),y
|
|
|
|
|
iny
|
|
|
|
|
jsr SRC.GetNextChar
|
|
|
|
|
bcc .1
|
|
|
|
|
|
|
|
|
|
.8 lda #0
|
|
|
|
|
sta (ZPNameBuf),y
|
|
|
|
|
clc
|
|
|
|
|
rts
|
|
|
|
|
|
|
|
|
|
.9 lda #ERR.SYNTAX.ERROR
|
|
|
|
|
sec
|
|
|
|
|
rts
|
|
|
|
|
*---------------------------------------
|
|
|
|
|
SYM.PC2Global ldx #4
|
|
|
|
|
|
|
|
|
|
ldy #ASM.PC
|
|
|
|
|
|
|
|
|
|
.1 lda (pData),y
|
|
|
|
|
pha
|
|
|
|
|
iny
|
|
|
|
|
dex
|
|
|
|
|
bne .1
|
|
|
|
|
|
|
|
|
|
ldx #4
|
|
|
|
|
|
|
|
|
|
ldy #SYMG.V+3
|
|
|
|
|
|
|
|
|
|
.2 pla
|
|
|
|
|
sta (ZPGlobalBuf),y
|
|
|
|
|
dey
|
|
|
|
|
dex
|
|
|
|
|
bne .2
|
|
|
|
|
|
|
|
|
|
ldx #4
|
|
|
|
|
ldy #ASM.PC+3
|
|
|
|
|
|
|
|
|
|
.3 lda (ZPGlobalBuf),y
|
|
|
|
|
bne .4
|
|
|
|
|
dex
|
|
|
|
|
dey
|
|
|
|
|
bne .3
|
|
|
|
|
|
|
|
|
|
.4 txa
|
|
|
|
|
|
|
|
|
|
ldy #SYMG.F
|
|
|
|
|
sta (ZPGlobalBuf),y
|
|
|
|
|
|
|
|
|
|
txa A=PC Size
|
|
|
|
|
|
|
|
|
|
rts
|
2018-01-24 16:24:06 +00:00
|
|
|
|
*---------------------------------------
|
2018-04-06 15:10:02 +00:00
|
|
|
|
SYM.Acc2Global ldx #4
|
|
|
|
|
ldy #SYMG.F+4
|
2018-03-28 15:23:32 +00:00
|
|
|
|
|
2018-04-06 15:10:02 +00:00
|
|
|
|
.1 lda SRC.ACC.SIZE,x
|
2018-03-28 15:23:32 +00:00
|
|
|
|
sta (ZPGlobalBuf),y
|
|
|
|
|
dey
|
|
|
|
|
dex
|
|
|
|
|
bpl .1
|
|
|
|
|
|
|
|
|
|
clc
|
|
|
|
|
rts
|
2018-01-24 16:24:06 +00:00
|
|
|
|
*---------------------------------------
|
2018-04-06 15:10:02 +00:00
|
|
|
|
SYM.Lookup2Acc ldy #SYMG.F+4
|
|
|
|
|
ldx #4
|
2018-03-28 15:23:32 +00:00
|
|
|
|
|
|
|
|
|
.1 lda (ZPLookupBuf),y
|
2018-04-06 15:10:02 +00:00
|
|
|
|
sta SRC.ACC.SIZE,x
|
2018-03-28 15:23:32 +00:00
|
|
|
|
dey
|
|
|
|
|
dex
|
2018-04-06 15:10:02 +00:00
|
|
|
|
bne .1
|
2018-03-28 15:23:32 +00:00
|
|
|
|
|
|
|
|
|
lda (ZPLookupBuf),y
|
|
|
|
|
and #SYMG.F.SIZE
|
|
|
|
|
sta SRC.ACC.SIZE
|
2018-01-24 16:24:06 +00:00
|
|
|
|
|
2018-03-28 15:23:32 +00:00
|
|
|
|
clc
|
|
|
|
|
rts
|
2015-10-04 20:55:51 +00:00
|
|
|
|
*---------------------------------------
|
2018-04-06 15:10:02 +00:00
|
|
|
|
* Local Symbol Record: (5 bytes)
|
2018-03-28 15:23:32 +00:00
|
|
|
|
* 0 : Local ID (1->255)
|
2018-04-06 15:10:02 +00:00
|
|
|
|
* 1-4 : 32 bits Value (PC)
|
2018-03-22 16:45:23 +00:00
|
|
|
|
*---------------------------------------
|
2018-03-28 15:23:32 +00:00
|
|
|
|
SYM.NewOrGetLocalA
|
|
|
|
|
tax Save ID
|
2018-04-06 15:10:02 +00:00
|
|
|
|
|
|
|
|
|
lda (ZPGlobalBuf) not in a global label
|
|
|
|
|
bne .1
|
|
|
|
|
|
|
|
|
|
lda #ERR.INV.LABEL
|
2018-03-28 15:23:32 +00:00
|
|
|
|
clc
|
|
|
|
|
rts
|
2018-04-06 15:10:02 +00:00
|
|
|
|
|
|
|
|
|
.1 >LDA.G ASM.PASS
|
|
|
|
|
bne SYM.LookupLocal.1 Pass #2: should be already defined...
|
|
|
|
|
|
|
|
|
|
SYM.NewLocal jsr SYM.LookupLocal.1 Pass #1; try to add
|
|
|
|
|
bcc .9 Already Defined
|
|
|
|
|
|
|
|
|
|
lda (ZPGlobalBuf)
|
2018-03-28 15:23:32 +00:00
|
|
|
|
tay
|
|
|
|
|
clc
|
|
|
|
|
adc #SYML.SIZE
|
2018-04-06 15:10:02 +00:00
|
|
|
|
bcs .90
|
2018-03-28 15:23:32 +00:00
|
|
|
|
|
2018-04-06 15:10:02 +00:00
|
|
|
|
ldy #ASM.PC+4
|
2018-03-28 15:23:32 +00:00
|
|
|
|
|
2018-04-06 15:10:02 +00:00
|
|
|
|
.1 dey
|
|
|
|
|
lda (pData),y
|
|
|
|
|
pha
|
|
|
|
|
cpy #ASM.PC
|
|
|
|
|
bne .1
|
|
|
|
|
|
|
|
|
|
lda (ZPGlobalBuf)
|
|
|
|
|
tay
|
2018-03-28 15:23:32 +00:00
|
|
|
|
iny
|
|
|
|
|
|
2018-04-06 15:10:02 +00:00
|
|
|
|
txa Get Back ID
|
2018-03-28 15:23:32 +00:00
|
|
|
|
|
2018-04-06 15:10:02 +00:00
|
|
|
|
sta (ZPGlobalBuf),y
|
2018-03-28 15:23:32 +00:00
|
|
|
|
|
|
|
|
|
ldx #4
|
|
|
|
|
|
|
|
|
|
.2 pla
|
|
|
|
|
iny
|
2018-04-06 15:10:02 +00:00
|
|
|
|
sta (ZPGlobalBuf),y
|
2018-03-28 15:23:32 +00:00
|
|
|
|
dex
|
|
|
|
|
bne .2
|
2018-03-23 15:57:35 +00:00
|
|
|
|
|
2018-03-28 15:23:32 +00:00
|
|
|
|
tya
|
|
|
|
|
sta (ZPGlobalBuf)
|
|
|
|
|
|
2018-04-06 15:10:02 +00:00
|
|
|
|
clc
|
2018-03-28 15:23:32 +00:00
|
|
|
|
rts
|
|
|
|
|
|
2018-04-06 15:10:02 +00:00
|
|
|
|
.90 lda #ERR.TOO.MANY.LOCAL
|
2018-03-28 15:23:32 +00:00
|
|
|
|
* sec
|
|
|
|
|
rts
|
2018-04-06 15:10:02 +00:00
|
|
|
|
|
|
|
|
|
.9 lda #ERR.SYMBOL.REDEF
|
|
|
|
|
sec
|
|
|
|
|
rts
|
2018-01-29 16:48:07 +00:00
|
|
|
|
*---------------------------------------
|
2018-04-06 15:10:02 +00:00
|
|
|
|
SYM.LookupLocal tax
|
|
|
|
|
SYM.LookupLocal.1
|
|
|
|
|
ldy #SYMG.SIZE
|
|
|
|
|
|
|
|
|
|
tya
|
|
|
|
|
|
|
|
|
|
.1 cmp (ZPGlobalBuf)
|
|
|
|
|
beq .9 CS if =
|
|
|
|
|
|
|
|
|
|
txa
|
|
|
|
|
iny
|
|
|
|
|
cmp (ZPGlobalBuf),y
|
|
|
|
|
beq .2
|
|
|
|
|
|
|
|
|
|
tya
|
|
|
|
|
clc
|
|
|
|
|
adc #SYML.SIZE-1
|
|
|
|
|
tay
|
|
|
|
|
bcc .1
|
|
|
|
|
|
|
|
|
|
.9 lda #ERR.UNDEF.SYMBOL
|
|
|
|
|
* sec
|
|
|
|
|
rts
|
|
|
|
|
|
|
|
|
|
.2 ldx #0
|
2018-01-26 16:19:17 +00:00
|
|
|
|
|
2018-04-06 15:10:02 +00:00
|
|
|
|
.3 iny
|
|
|
|
|
|
|
|
|
|
lda (ZPGlobalBuf),y
|
|
|
|
|
sta SRC.ACC,x
|
|
|
|
|
inx
|
|
|
|
|
cpx #4
|
|
|
|
|
bne .3
|
2018-01-26 16:19:17 +00:00
|
|
|
|
|
2018-03-28 15:23:32 +00:00
|
|
|
|
clc
|
|
|
|
|
rts
|
|
|
|
|
*---------------------------------------
|
|
|
|
|
* Private Symbol Record: (9 bytes)
|
|
|
|
|
* 0 : Len (8)
|
|
|
|
|
* 1 : Flags:
|
|
|
|
|
* b7=0=pending,1=resolved
|
|
|
|
|
* 2-5 : 32 bits Value (PC)
|
|
|
|
|
* 6,7 : MCID (Macro Context ID)
|
|
|
|
|
* 8 : Private ID (0->255)
|
2015-10-04 20:55:51 +00:00
|
|
|
|
*---------------------------------------
|
2018-01-22 07:34:59 +00:00
|
|
|
|
SYM.AddPrivate
|
2018-03-28 15:23:32 +00:00
|
|
|
|
clc
|
|
|
|
|
rts
|
2015-10-04 20:55:51 +00:00
|
|
|
|
*---------------------------------------
|
2018-01-22 07:34:59 +00:00
|
|
|
|
SYM.LookupPrivate
|
2018-03-28 15:23:32 +00:00
|
|
|
|
clc
|
|
|
|
|
rts
|
2015-11-27 16:26:11 +00:00
|
|
|
|
*---------------------------------------
|
2015-10-04 20:55:51 +00:00
|
|
|
|
MAN
|
2018-01-10 16:34:57 +00:00
|
|
|
|
SAVE /A2OSX.BUILD/BIN/DEV/ASM.S.SYM
|
|
|
|
|
LOAD /A2OSX.BUILD/BIN/DEV/ASM.S
|
2015-10-04 20:55:51 +00:00
|
|
|
|
ASM
|