aboutsummaryrefslogtreecommitdiffstats
path: root/asmsrc/bac80r.asm
diff options
context:
space:
mode:
Diffstat (limited to 'asmsrc/bac80r.asm')
-rw-r--r--asmsrc/bac80r.asm13
1 files changed, 5 insertions, 8 deletions
diff --git a/asmsrc/bac80r.asm b/asmsrc/bac80r.asm
index 3db24db..5d52dc4 100644
--- a/asmsrc/bac80r.asm
+++ b/asmsrc/bac80r.asm
@@ -32,19 +32,16 @@ _start:
ex de,hl
push bc ; String length
push de ; String address
+ push bc ; Bytes occupied on the stack
ld a,(hl) ; First character in chain string
ldir
- push bc ; Dummy argument (=0)
- ld c,END
+ ld hl,END
cp a,':' ; Bogus name -> END, not CHAIN ""
jr z,gotretn
- ld bc,XCHAINo
- ld a,(bc)
- cp 0CDh ; Old BASIC?
- jr z,gotretn
- ld c,XCHAINn & 0xff ; No, it's new BASIC
+ ld hl,(CHAINPTR) ; Pointer to the CHAIN routine
+ inc hl ; Skip RST 56h -> eval expression
gotretn:
- push bc ; Return address
+ push hl ; Return address
ld de,(BOFA) ; BOFA = start of data
push de ; Save for done