This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
scoping of numeric local labels in assembler macros
- From: Greg McGary <greg at mcgary dot org>
- To: binutils at sources dot redhat dot com
- Cc: greg at mcgary dot org
- Date: 07 Jun 2002 17:54:45 -0700
- Subject: scoping of numeric local labels in assembler macros
I have the displeasure of working with a large collection of assembler
macros, which are often nested. They make liberal use of
small-integer local labels which are vulnerable to collisions. (E.g.,
macro A calls macro B, both use label `1', so A silently branches to a
location in B, rather than the intended destination in A)
It occurs to me that it would be useful if local labels could be
scoped within macros. Has this been discussed before? If I implement
it, will the community want the changes? Since this is a major change
in semantics, it will only be enabled by a command-line option, and
off by default.
Greg