gbdk-2020 | GameBoy Development Kit |
| download: https://git.y1.nz/archives/gbdk.tar.gz | |
| README | Files | Log | Refs | LICENSE |
commit 9f32f7c9aa1f2f224962eb35738447d9b5a2c523 parent 770883b3bad87ce65c6a006a7ca25b8e93079826 Author: Toxa <untoxa@mail.ru> Date: Sat, 28 May 2022 23:18:53 +0300 minor style Diffstat:
| M | gbdk-lib/libc/targets/sm83/___sdcc_bcall.s | 26 | +++++++++++++------------- |
| M | gbdk-lib/libc/targets/sm83/___sdcc_bcall_ehl.s | 16 | ++++++++-------- |
2 files changed, 21 insertions(+), 21 deletions(-)
diff --git a/gbdk-lib/libc/targets/sm83/___sdcc_bcall.s b/gbdk-lib/libc/targets/sm83/___sdcc_bcall.s @@ -5,26 +5,26 @@ ___sdcc_bcall:: banked_call:: ; Performs a long call. pop hl ; Get the return address - ldh a,(__current_bank) + ldh a, (__current_bank) push af ; Push the current bank onto the stack - ld a,(hl+) ; Fetch the call address + ld a, (hl+) ; Fetch the call address ld e, a - ld a,(hl+) + ld a, (hl+) ld d, a - ld a,(hl+) ; ...and page + ld a, (hl+) ; ...and page inc hl ; Yes this should be here push hl ; Push the real return address - ldh (__current_bank),a - ld (.MBC_ROM_PAGE),a ; Perform the switch - ld l,e - ld h,d + ldh (__current_bank), a + ld (.MBC_ROM_PAGE), a ; Perform the switch + ld l, e + ld h, d rst 0x20 banked_ret:: pop hl ; Get the return address pop bc ; Pop the old bank - ld c, a - ld a, b - ldh (__current_bank),a - ld (.MBC_ROM_PAGE),a - ld a, c ; we must preserve A for the new calling convention + ld c, a + ld a, b + ldh (__current_bank), a + ld (.MBC_ROM_PAGE), a + ld a, c ; we must preserve A for the new calling convention jp (hl) diff --git a/gbdk-lib/libc/targets/sm83/___sdcc_bcall_ehl.s b/gbdk-lib/libc/targets/sm83/___sdcc_bcall_ehl.s @@ -3,16 +3,16 @@ .area _HOME ___sdcc_bcall_ehl:: ; Performs a long call. - ldh a,(__current_bank) + ldh a, (__current_bank) push af ; Push the current bank onto the stack ld a, e - ldh (__current_bank),a - ld (.MBC_ROM_PAGE),a ; Perform the switch + ldh (__current_bank), a + ld (.MBC_ROM_PAGE), a ; Perform the switch rst 0x20 pop bc ; Pop the old bank - ld c, a - ld a, b - ldh (__current_bank),a - ld (.MBC_ROM_PAGE),a - ld a, c + ld c, a + ld a, b + ldh (__current_bank), a + ld (.MBC_ROM_PAGE), a + ld a, c ret
This webpage is intended to be an accessible preview of this repository. To get a fuller picture, clone it and use the git CLI.