2021-12-02 21:28:26 +00:00
|
|
|
|
NEW
|
|
|
|
|
AUTO 3,1
|
|
|
|
|
*--------------------------------------
|
2022-10-07 19:21:37 +00:00
|
|
|
|
DIR jsr CORE.GetNCharNB
|
|
|
|
|
bcs .91
|
2021-12-02 21:28:26 +00:00
|
|
|
|
|
2022-10-07 19:21:37 +00:00
|
|
|
|
>LDYA L.CC.DIRS
|
2021-12-02 21:28:26 +00:00
|
|
|
|
jsr CC.LookupID
|
|
|
|
|
bcs .91
|
|
|
|
|
|
|
|
|
|
jmp (J.CC.DIRS,x)
|
|
|
|
|
|
|
|
|
|
.91 lda #E.CSYN
|
|
|
|
|
sec
|
|
|
|
|
.99 rts
|
|
|
|
|
*--------------------------------------
|
2022-10-07 19:21:37 +00:00
|
|
|
|
DIR.DEFINE clc
|
2022-06-12 20:42:22 +00:00
|
|
|
|
bit bPass2
|
|
|
|
|
bmi .8
|
2023-01-21 21:53:55 +00:00
|
|
|
|
|
2022-06-12 20:42:22 +00:00
|
|
|
|
jsr CC.CheckSpace
|
2023-01-23 18:33:37 +00:00
|
|
|
|
bcs .90
|
2021-12-02 21:28:26 +00:00
|
|
|
|
|
|
|
|
|
jsr CC.IsLetter
|
|
|
|
|
bcs .90
|
|
|
|
|
|
2022-06-12 20:42:22 +00:00
|
|
|
|
ldx #SYM.SC.DEFINE
|
2021-12-02 21:28:26 +00:00
|
|
|
|
>LDA.G CC.hDefines
|
2022-10-07 19:21:37 +00:00
|
|
|
|
jsr SYM.NewKey
|
2021-12-02 21:28:26 +00:00
|
|
|
|
bcs .99
|
|
|
|
|
|
2022-06-12 20:42:22 +00:00
|
|
|
|
>STYA ZPPtr1 SymID
|
2021-12-02 21:28:26 +00:00
|
|
|
|
|
2022-02-04 14:57:17 +00:00
|
|
|
|
jsr CC.SkipX
|
|
|
|
|
|
2021-12-02 21:28:26 +00:00
|
|
|
|
jsr CC.CheckSpace
|
|
|
|
|
bcs .99
|
|
|
|
|
|
|
|
|
|
ldy #$ff
|
|
|
|
|
|
|
|
|
|
.1 iny
|
|
|
|
|
lda (ZPLineBufPtr),y
|
|
|
|
|
beq .2
|
|
|
|
|
|
|
|
|
|
cmp #C.CR
|
|
|
|
|
bne .1
|
|
|
|
|
|
|
|
|
|
dey
|
|
|
|
|
|
|
|
|
|
.2 iny
|
|
|
|
|
|
|
|
|
|
phy
|
|
|
|
|
|
|
|
|
|
>PUSHB.G CC.hDefines
|
2022-06-12 20:42:22 +00:00
|
|
|
|
>PUSHW ZPPtr1 SymID
|
2021-12-02 21:28:26 +00:00
|
|
|
|
>PUSHW ZPLineBufPtr
|
|
|
|
|
|
|
|
|
|
ply
|
|
|
|
|
lda #0
|
|
|
|
|
>PUSHYA DataLen
|
|
|
|
|
|
|
|
|
|
>SYSCALL SListAddData
|
|
|
|
|
bcs .99
|
|
|
|
|
|
2022-10-07 19:21:37 +00:00
|
|
|
|
.8 jmp CORE.SkipLine
|
2021-12-02 21:28:26 +00:00
|
|
|
|
|
|
|
|
|
.90 lda #E.CSYN
|
|
|
|
|
sec
|
|
|
|
|
.99 rts
|
|
|
|
|
*--------------------------------------
|
2022-10-07 19:21:37 +00:00
|
|
|
|
DIR.INCLUDE lda #0 >STZ.G PathBuf
|
2021-12-02 21:28:26 +00:00
|
|
|
|
sta (pData)
|
|
|
|
|
|
|
|
|
|
jsr CC.CheckSpace
|
|
|
|
|
bcs .99
|
|
|
|
|
|
|
|
|
|
cmp #'"'
|
|
|
|
|
beq .1
|
|
|
|
|
|
|
|
|
|
cmp #'<'
|
|
|
|
|
bne .90
|
|
|
|
|
|
|
|
|
|
>PUSHW L.ENV.INCLUDE
|
|
|
|
|
>PUSHW pData >PUSHEA.G PathBuf
|
|
|
|
|
>SYSCALL GetEnv
|
|
|
|
|
bcs .90
|
2023-01-21 21:53:55 +00:00
|
|
|
|
|
2021-12-02 21:28:26 +00:00
|
|
|
|
lda #'>'
|
|
|
|
|
|
|
|
|
|
.1 sta ArgIndex
|
|
|
|
|
|
|
|
|
|
ldy #$ff
|
|
|
|
|
|
|
|
|
|
.2 iny
|
|
|
|
|
lda (pData),y
|
|
|
|
|
bne .2
|
|
|
|
|
|
|
|
|
|
.3 jsr CC.GetNextChar
|
|
|
|
|
beq .90
|
|
|
|
|
|
|
|
|
|
cmp ArgIndex
|
2022-06-12 20:42:22 +00:00
|
|
|
|
beq .4
|
2021-12-02 21:28:26 +00:00
|
|
|
|
|
|
|
|
|
sta (pData),y
|
|
|
|
|
iny
|
2022-06-12 20:42:22 +00:00
|
|
|
|
cpy #MLI.MAXPATH
|
2021-12-02 21:28:26 +00:00
|
|
|
|
bne .3
|
|
|
|
|
|
|
|
|
|
.90 lda #E.CSYN
|
|
|
|
|
sec
|
|
|
|
|
.99 rts
|
|
|
|
|
|
2022-06-12 20:42:22 +00:00
|
|
|
|
.4 phy
|
2021-12-02 21:28:26 +00:00
|
|
|
|
jsr CC.GetNextChar skip " or >
|
2022-06-12 20:42:22 +00:00
|
|
|
|
ply
|
2021-12-02 21:28:26 +00:00
|
|
|
|
|
2022-06-12 20:42:22 +00:00
|
|
|
|
lda #0
|
|
|
|
|
sta (pData),y terminate string
|
2023-01-21 21:53:55 +00:00
|
|
|
|
|
2022-12-13 06:55:13 +00:00
|
|
|
|
>LDYA pData
|
2022-10-07 19:21:37 +00:00
|
|
|
|
jmp FIO.FOpen
|
|
|
|
|
*--------------------------------------
|
2023-01-27 13:32:13 +00:00
|
|
|
|
DIR.IFDEF clc
|
|
|
|
|
.HS B0 BCS
|
|
|
|
|
DIR.IFNDEF sec
|
2023-01-23 18:33:37 +00:00
|
|
|
|
|
|
|
|
|
ror ZPPtr1
|
|
|
|
|
|
|
|
|
|
jsr CC.CheckSpace
|
|
|
|
|
bcs DIR.ESYN
|
|
|
|
|
|
|
|
|
|
jsr CC.IsLetter
|
|
|
|
|
bcs DIR.ESYN
|
|
|
|
|
|
|
|
|
|
>PUSHB.G CC.hDefines
|
|
|
|
|
>PUSHW ZPLineBufPtr
|
|
|
|
|
>PUSHWI 0 ScopeID
|
|
|
|
|
>SYSCALL SListLookup
|
2023-01-27 13:32:13 +00:00
|
|
|
|
|
2023-01-23 18:33:37 +00:00
|
|
|
|
ror
|
|
|
|
|
eor ZPPtr1
|
|
|
|
|
asl
|
|
|
|
|
|
2023-01-26 16:38:20 +00:00
|
|
|
|
>LDA.G CC.DirState
|
2023-01-27 13:32:13 +00:00
|
|
|
|
ror
|
2023-01-26 16:38:20 +00:00
|
|
|
|
sta (pData),y
|
2023-01-27 13:32:13 +00:00
|
|
|
|
|
2023-01-26 16:38:20 +00:00
|
|
|
|
>DEC.G CC.DirDepth
|
2023-01-27 13:32:13 +00:00
|
|
|
|
cmp #$F8
|
|
|
|
|
bcs .8
|
|
|
|
|
|
|
|
|
|
lda #E.OOB
|
|
|
|
|
sec
|
|
|
|
|
rts
|
|
|
|
|
|
|
|
|
|
.8 clc
|
2023-01-23 18:33:37 +00:00
|
|
|
|
rts
|
|
|
|
|
*--------------------------------------
|
2023-01-26 16:38:20 +00:00
|
|
|
|
DIR.ELSE >LDA.G CC.DirDepth
|
2023-01-23 18:33:37 +00:00
|
|
|
|
beq DIR.ESYN
|
|
|
|
|
|
2023-01-26 16:38:20 +00:00
|
|
|
|
>LDA.G CC.DirState
|
2023-01-23 18:33:37 +00:00
|
|
|
|
eor #$80
|
2023-01-26 16:38:20 +00:00
|
|
|
|
sta (pData),y
|
2023-01-23 18:33:37 +00:00
|
|
|
|
clc
|
|
|
|
|
rts
|
|
|
|
|
*--------------------------------------
|
2023-01-26 16:38:20 +00:00
|
|
|
|
DIR.ENDIF >LDA.G CC.DirDepth
|
2023-01-23 18:33:37 +00:00
|
|
|
|
beq DIR.ESYN
|
2023-01-26 16:38:20 +00:00
|
|
|
|
|
2023-01-27 13:32:13 +00:00
|
|
|
|
inc
|
2023-01-26 16:38:20 +00:00
|
|
|
|
sta (pData),y
|
2023-01-23 18:33:37 +00:00
|
|
|
|
|
2023-01-26 16:38:20 +00:00
|
|
|
|
>LDA.G CC.DirState
|
2023-01-23 18:33:37 +00:00
|
|
|
|
asl
|
2023-01-26 16:38:20 +00:00
|
|
|
|
sta (pData),y
|
2023-01-23 18:33:37 +00:00
|
|
|
|
|
|
|
|
|
clc
|
|
|
|
|
rts
|
|
|
|
|
|
|
|
|
|
DIR.ESYN lda #E.ESYN
|
|
|
|
|
sec
|
|
|
|
|
rts
|
2021-12-02 21:28:26 +00:00
|
|
|
|
*--------------------------------------
|
|
|
|
|
MAN
|
|
|
|
|
SAVE usr/src/bin/cc.s.dir
|
|
|
|
|
LOAD usr/src/bin/cc.s
|
|
|
|
|
ASM
|