This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Deprecating GCC extensions...
- To: Fergus Henderson <fjh at cs dot mu dot oz dot au>
- Subject: Re: Deprecating GCC extensions...
- From: Andi Kleen <ak at suse dot de>
- Date: 05 Mar 2001 16:34:31 +0100
- Cc: gcc at gcc dot gnu dot org
- References: <20010228232827.A12658@daikokuya.demon.co.uk> <20010301145100.A22921@hg.cs.mu.oz.au>
Fergus Henderson <fjh@cs.mu.oz.au> writes:
> On 28-Feb-2001, Neil Booth <neil@daikokuya.demon.co.uk> wrote:
> > Whilst we're on the topic of deprecating extensions, is there any support
> > for deprecating multi-line strings for GCC 3.0?
>
> That particular GCC extension is one that I've only ever seen used by
> accident, and often causes portability problems in Mercury code.
I've seen it very often, especially in Linux low level code. It is very useful
to write readable inline assembler.
Compare:
asm("movl x,y\n\t"
"movl y,z\n\t"
"cmpl bla,blub\n\t")
to
asm("movl x,y
movl y,z
cmpl bla,blub");
The second is clearly more readable. I guess if you really wanted to deprecate
it you would need to supply some alternative to make the assembler readable again.
I suspect you'll break quite a lot of code though.
-Andi