cp '('\r
jr z,fact_mem\r
cp '['\r
- jp z,expr_brckt\r
+ jr z,expr_brckt\r
cp ''''\r
jr z,fact_factstring\r
+ cp '.'\r
+ jr z,fact_symbol\r
dec de\r
scf\r
ret\r
\r
fact_reg.Y:\r
call get.decdigit\r
- jp c,ERROR\r
+ jr c,error4\r
inc de\r
add a,a\r
ld hl,reg_Y\r
error4:\r
jp ERROR\r
\r
+fact_symbol:\r
+ push bc\r
+ ld hl,ddtz_base\r
+\r
+fs_nxtsym:\r
+ ld a,(hl) ;symlen\r
+ cp 0c3h\r
+ jr z,error4\r
+ ld b,a\r
+ inc b\r
+ push hl\r
+ push de\r
+fs_2:\r
+ ld a,(de)\r
+ call test_termchar\r
+ jr z,fs_endstr\r
+ dec b\r
+ jr z,fs_cont\r
+ inc de\r
+ dec hl\r
+ cp (hl)\r
+ jr z,fs_2\r
+fs_cont:\r
+ pop de\r
+ pop hl\r
+ ld a,(hl)\r
+ add a,3\r
+ call sub_hl_a\r
+ jr fs_nxtsym\r
+\r
+fs_endstr:\r
+ dec b\r
+ jr nz,fs_cont\r
+ pop hl\r
+ pop hl\r
+ inc hl\r
+ ld a,(hl)\r
+ inc hl\r
+ ld h,(hl)\r
+ ld l,a\r
+ or a\r
+ pop bc\r
+ ret\r
+\r
+t_trmchrs:\r
+ db ' !#&()*+,-/:;<=>[\]{|}',0\r
+t_trmchrs_len equ $ - t_trmchrs\r
+\r
+test_termchar:\r
+ push hl\r
+ push bc\r
+ ld hl,t_trmchrs\r
+ ld bc,t_trmchrs_len\r
+ cpir\r
+ pop bc\r
+ pop hl\r
+ ret\r
+\r
+\r
+\r
get.number:\r
call get.hexdigit\r
ret c\r
call out_hl_dec_neg\r
call outbl4\r
call out.bin.w\r
- call outbl2\r
+ call outbl\r
ld a,l\r
call out.ascii\r
+ call outbl\r
+ call p_symbol\r
jp crlf\r
\r
p_symbols:\r
ld b,(hl)\r
dec hl\r
ld a,b\r
- cp 10h\r
- ret nc\r
+ cp 0c3h\r
+ ret z\r
\r
ex de,hl\r
call out_hl\r
call crlf\r
jr psym_l\r
\r
+\r
+p_symbol:\r
+ if 0\r
+ ld a,(dash_flag)\r
+ or a\r
+ ret nz\r
+ endif\r
+ call sym_getname\r
+ ret z\r
+ ld a,'.'\r
+ call outchar\r
p_symstr:\r
ld b,(hl)\r
pss_l:\r
djnz pss_l\r
ret\r
\r
-\r
p_label:\r
if 0\r
ld a,(dash_flag)\r
DC ' Max = '\r
ld hl,(max_load)\r
call out_hl\r
+ call pstr_inl\r
+ DC ' Top = '\r
+ ld hl,(BDOS+1)\r
+ call out_hl\r
jp crlf\r
\r
cmd_W:\r