mirror of
https://github.com/A2osX/A2osX.git
synced 2024-11-22 00:32:44 +00:00
83 lines
1.3 KiB
Plaintext
83 lines
1.3 KiB
Plaintext
NEW
|
||
AUTO 3,1
|
||
.LIST OFF
|
||
*--------------------------------------
|
||
CC.DECL jsr CC.IsLetter
|
||
bcs .80
|
||
|
||
.10 >LDYA L.CC.SCSPEC
|
||
jsr CC.LookupID
|
||
bcs .20
|
||
|
||
* TODO: typedef ....
|
||
|
||
bcs .90
|
||
|
||
.20 >LDYA L.CC.TYPEQUAL
|
||
jsr CC.LookupID
|
||
bcs .80
|
||
|
||
jsr CC.TYPE.Decl
|
||
bcs .99
|
||
|
||
ldx #SYM.SC.STATIC Y,A = Type/Qual
|
||
bit ScopenCnt
|
||
bpl .21
|
||
|
||
bit #SYM.Q.FUNC someone wants to add a local f() ?
|
||
bne .90
|
||
|
||
ldx #SYM.SC.AUTO
|
||
|
||
.21 jsr CC.SYM.New Y,A=T/Q, add with undef value...
|
||
bcs .99
|
||
|
||
jsr CC.SYM.Store
|
||
bcs .99
|
||
|
||
* TODO: AOPS
|
||
|
||
cmp #'='
|
||
bne .90
|
||
|
||
jsr CC.GetNextCharNB skip '='
|
||
bcs .99
|
||
|
||
jsr CC.SYM.GetTypeInYA expected T/Q
|
||
jsr CC.EXP.Eval
|
||
bcs .99
|
||
|
||
jsr CC.SYM.PopValue Y,A = T/Q, Set value to this var
|
||
.29 bcs .99
|
||
|
||
|
||
jsr CC.SYM.FreeBuf
|
||
|
||
clv
|
||
clc
|
||
rts
|
||
|
||
.80 bit #$60
|
||
clc
|
||
rts
|
||
|
||
.90 lda #E.CSYN
|
||
sec
|
||
.99 rts
|
||
*--------------------------------------
|
||
CC.SCSPEC.AUTO
|
||
CC.SCSPEC.REGISTER
|
||
CC.SCSPEC.STATIC
|
||
CC.SCSPEC.EXTERN
|
||
CC.SCSPEC.TYPEDEF
|
||
|
||
|
||
.99 lda #E.CSYN
|
||
sec
|
||
.9 rts
|
||
*--------------------------------------
|
||
MAN
|
||
SAVE usr/src/bin/cc.s.decl
|
||
LOAD usr/src/bin/cc.s
|
||
ASM
|