[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: warnings compiling Emacs 22 on amd64

From: Kim F. Storm
Subject: Re: warnings compiling Emacs 22 on amd64
Date: Tue, 16 Jan 2007 09:47:55 +0100
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.92 (gnu/linux)

Kevin Gallagher <address@hidden> writes:

> Some compilers support the use of #pragma directives to disable
> certain warnings it would
> otherwise generate for the lines wrapped within those specific #pragma
> directives.  Perhaps
> GCC could be extended to support this.
> I think this, or some other in line compiler directive, is a better
> way to instruct the compiler
> how to behave, rather than a modification of the source code itself.

The problem with a #pragma is that you need to wrap every _use_ of the
macro, rather than localizing the trickery to the macro definition.

Of course, if you could define it like this:

#define MACRO(i) \
#pragma specific_warning_off\
macro definition here\
#pragma specific_warning_on

it would be ok to use a pragma.

But how would that work if you write something like

  var = MACRO(i)


Kim F. Storm <address@hidden> http://www.cua.dk

reply via email to

[Prev in Thread] Current Thread [Next in Thread]