This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug inline-asm/31693] Incorrectly assigned registers to operands for ARM inline asm



------- Comment #8 from rearnsha at gcc dot gnu dot org  2009-02-10 15:21 -------
Opinions vary wildly as to which warnings should be on by default, and which
should be part of whatever bundle.

I personally agree that shadowing variables is generally bad practice, but you
then have to be wary when porting code because you can end up shadowing things
that come from a library (different standard libraries contain all sorts of
wild and wacky variables or functions, most of which you'll never care about). 
For example:

#include <stdio.h>

int f()
{
  int printf = 3; return printf;
}

will generate a warning if compiled with -Wshadow (ok, that's somewhat
perverse, since every library has printf, but it makes the point).


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31693


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]