Newbie question #31020.
So, I can use this FOR syntax to do two-pass assembly:
Code:
FOR pass=0 TO 2 STEP 2
P%=&1900
[OPT pass
LDA &0
JMP later
LDA &1B
RTS
BRK
.later
LDY #0
RTS
]
NEXT
and pick up labels which are later in the routine.
Now, suppose I want to assemble a second, different routine at a different location in memory.
Code:
FOR pass=0 TO 2 STEP 2
P%=&2400
[OPT pass
LDA &0
JMP laterroutine2
LDA &1B
RTS
BRK
.laterroutine2
LDY #0
RTS
]
NEXT
Is there anyway of compiling the two together so that you can use labels in the first routine which are actually pointing to the second routine? e.g. in the above examples, so you could use the label .laterroutine2 in the first routine which is stored at &1900.
Or if that's not possible I assume the only option in this case would be to resort to manually recording .laterroutine2's memory location and storing that in a variable in routine 1?
Not urgent, but I'm curious as to the answer ...
Sam.