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 c/42440] optimization bug with btwowc(EOF) in wchar.h



------- Comment #6 from pinskia at gcc dot gnu dot org  2009-12-21 00:32 -------
(In reply to comment #4)
> > Works for me.  The preprocessed source is certainly not what was compiled
> 
> Yes, it was.  But I apologize, the invocation needs to include -std=gnu99 to
> observe the problem, e.g., gcc -std=gnu99 -O2 conftest.i.  Without that option,
> indeed, the resulting executables runs ok.


In fact if you are using -std=gnu99 then the behavior here is correct to the
C99 standard's "extern inline" behavior.  the function is exported no matter
what for extern inline in C99, this is why gnu_inline exists.


-- 


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


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