Mail Archives: djgpp/1997/01/28/16:25:59
Paul Lay wrote:
>
> Is it possible to use local labels from in-line assembler
> in a C function?
>
> I've tried using "L<x>" labels, which would be local if I
> were writing straight assembler, but compiling my C program
> gives label already defined errors where I've used the same
> "L<x>" label in different functions.
Those are the wrong sort of local labes. You use '0' to '9' (giving 10
local labels in each direction)
eg
0: jmp 0f jumps v
1: jmp 2f jumps v one line
2: jmp 3f jumps v
...
0: jmp 0b jumps ^
1: jmp 2b jumps ^
2: jmp 1b jumps ^ one line
3: ...
Bill
--
Leave others their otherness.
- Raw text -