An argument used to define a label within a macro does not work as expected. Consider the following macro:
.macro deflabel
@0:
.endm
One would expect the invocation:
deflabel RightHere
to generate
Righthere:
But it doesn't. This can be gotten around by redefining the macro as:
.macro genlabel
.equ @0 = PC
.endm
So it's not a stopper, but the behavior is a bit strange.
I am not sure what AvrAsm does in this case, but avra keeps all macro labels local to the macro, because otherwise it would be difficult to expand multiple invocations of a macro:
.macro deflabel
macrolabel:
jmp macrolabel
.endm
.org 100
C:000064 + deflabel
macrolabel:
C:000064 940c 0064 jmp macrolabel
C:000066 + deflabel
macrolabel:
C:000066 940c 0066 jmp macrolabel
OverThere:
C:000068 940c 0068 jmp OverThere
"macrolabel" is defined as a label that is *local* to the macro invocation, therefore
it can be used multiple times.
I think this is correct and this is not a bug.