This commit is contained in:
Michael Steil 2008-10-11 22:37:02 +00:00
parent b183d3ba34
commit 8fc6b95bae

145
msbasic.s
View File

@ -175,70 +175,6 @@ TOKEN_NAME_TABLE:
.endif .endif
keyrts "NEW", NEW keyrts "NEW", NEW
; keyrts "",
; keyrts "",
; keyrts "",
; keyrts "",
.segment "VECTORS"
UNFNC:
.addr SGN
.addr INT
.addr ABS
.ifdef KIM
.addr IQERR
.else
.ifdef KBD
.addr VER
.else
.addr USR
.endif
.endif
.addr FRE
.addr POS
.addr SQR
.addr RND
.addr LOG
.addr EXP
.addr COS
.addr SIN
.addr TAN
.addr ATN
.ifdef KBD
.addr GETC
.else
.addr PEEK
.endif
.addr LEN
.addr STR
.addr VAL
.addr ASC
.addr CHRSTR
.addr LEFTSTR
.addr RIGHTSTR
.addr MIDSTR
MATHTBL:
.byte $79
.word FADDT-1
.byte $79
.word FSUBT-1
.byte $7B
.word FMULTT-1
.byte $7B
.word FDIVT-1
.byte $7F
.word FPWRT-1
.byte $50
.word TAND-1
.byte $46
.word OR-1
.byte $7D
.word NEGOP-1
.byte $5A
.word EQUOP-1
.byte $64
.word RELOPS-1
.segment "KEYWORDS" .segment "KEYWORDS"
htasc "TAB(" htasc "TAB("
htasc "TO" htasc "TO"
@ -261,41 +197,72 @@ MATHTBL:
htasc ">" htasc ">"
htasc "=" htasc "="
htasc "<" htasc "<"
htasc "SGN"
htasc "INT" .segment "VECTORS"
htasc "ABS" UNFNC:
keyvec "SGN", SGN
keyvec "INT", INT
keyvec "ABS", ABS
.ifdef KBD .ifdef KBD
htasc "VER" keyvec "VER", VER
.else .else
htasc "USR" .ifdef KIM
keyvec "USR", IQERR
.else
keyvec "USR", USR
.endif .endif
htasc "FRE" .endif
htasc "POS" keyvec "FRE", FRE
htasc "SQR" keyvec "POS", POS
htasc "RND" keyvec "SQR", SQR
htasc "LOG" keyvec "RND", RND
htasc "EXP" keyvec "LOG", LOG
htasc "COS" keyvec "EXP", EXP
htasc "SIN" keyvec "COS", COS
htasc "TAN" keyvec "SIN", SIN
htasc "ATN" keyvec "TAN", TAN
keyvec "ATN", ATN
.ifdef KBD .ifdef KBD
htasc "GETC" keyvec "GETC", GETC
.else .else
htasc "PEEK" keyvec "PEEK", PEEK
.endif .endif
htasc "LEN" keyvec "LEN", LEN
htasc "STR$" keyvec "STR$", STR
htasc "VAL" keyvec "VAL", VAL
htasc "ASC" keyvec "ASC", ASC
htasc "CHR$" keyvec "CHR$", CHRSTR
htasc "LEFT$" keyvec "LEFT$", LEFTSTR
htasc "RIGHT$" keyvec "RIGHT$", RIGHTSTR
htasc "MID$" keyvec "MID$", MIDSTR
.ifdef CBM2_KBD .ifdef CBM2_KBD
htasc "GO" htasc "GO"
.endif .endif
.byte 0 .byte 0
.segment "VECTORS"
MATHTBL:
.byte $79
.word FADDT-1
.byte $79
.word FSUBT-1
.byte $7B
.word FMULTT-1
.byte $7B
.word FDIVT-1
.byte $7F
.word FPWRT-1
.byte $50
.word TAND-1
.byte $46
.word OR-1
.byte $7D
.word NEGOP-1
.byte $5A
.word EQUOP-1
.byte $64
.word RELOPS-1
.segment "CODE" .segment "CODE"
ERROR_MESSAGES: ERROR_MESSAGES:
.ifdef CONFIG_SMALL .ifdef CONFIG_SMALL