This is probably related to bug #60
I have this code
;;
;; common.asm contains macros that would be usefull with any demo system.
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; MEMORY HANDLING ;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
macro DS_PRODUCE_CRC16_SUM_ROUTINE
ds_crc16_sum
DS_CRC16_SUM()
ret
endm
;; Compute the CRC16 sum of a data block.
;; Input:
;; - HL: pointer to the data block
;; - BC: length of the data block
;; Output:
;; - DE: CRC16 sum of the data block
;; Clobbers:
macro DS_CRC16_SUM
ld de, 0
@loop
ld a, (hl) : inc hl
add e
ld a, d : adc a, 0: ld e, a
dec bc
ld a, b
cp c
jr nz @loop
endm
That displays the following error
error: error: error: Error in macro call DS_PRODUCE_CRC16_SUM_ROUTINE (defined in ../linking/src/demosystem/common.asm:10:2)
┌─ ../linking/src/load_outer_space.asm:68:2
│
68 │ DS_PRODUCE_CRC16_SUM_ROUTINE()
│ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: error: Syntax error
┌─ ../linking/src/demosystem/common.asm:23:2 > MACRO DS_CRC16_SUM::12:1
│
12 │ jr nz @loop
│ ^^^^^^^^^^^^^^^^^^^ Unknown error
┌─ ../linking/src/demosystem/common.asm:10:2 > MACRO DS_PRODUCE_CRC16_SUM_ROUTINE::3:2
│
3 │ DS_CRC16_SUM()
│ ^^^^^^^^^^^^^^
68 is w wrong number, it should be 10
12 is the relative line inside the macro, it should be 34
3 is the relative line instide the macro, it should be 12
This is probably related to bug #60
I have this code
That displays the following error
68 is w wrong number, it should be 10
12 is the relative line inside the macro, it should be 34
3 is the relative line instide the macro, it should be 12