[Bug preprocessor/41590] No __STDC__ definition in -g3 -E output on STDC_0_IN_SYSTEM_HEADERS systems

2017-02-08 Thread ro at CeBiTec dot Uni-Bielefeld.DE
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=41590

--- Comment #4 from ro at CeBiTec dot Uni-Bielefeld.DE  ---
> --- Comment #3 from Martin Sebor  ---
> Documentation patch:
> https://gcc.gnu.org/ml/gcc-patches/2017-02/msg00560.html

I think you got the wrong PR here: your doc patch is about PR
preprocessor/41540, not 41590, which AFAICT is unrelated.

Rainer

[Bug preprocessor/41590] No __STDC__ definition in -g3 -E output on STDC_0_IN_SYSTEM_HEADERS systems

2017-02-07 Thread msebor at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=41590

Martin Sebor  changed:

   What|Removed |Added

   Keywords||documentation, patch
 CC||msebor at gcc dot gnu.org
   Assignee|unassigned at gcc dot gnu.org  |msebor at gcc dot 
gnu.org

--- Comment #3 from Martin Sebor  ---
Documentation patch:
https://gcc.gnu.org/ml/gcc-patches/2017-02/msg00560.html

[Bug preprocessor/41590] No __STDC__ definition in -g3 -E output on STDC_0_IN_SYSTEM_HEADERS systems

2013-05-08 Thread skannan at redhat dot com


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



Shakthi Kannan skannan at redhat dot com changed:



   What|Removed |Added



 CC||skannan at redhat dot com



--- Comment #1 from Shakthi Kannan skannan at redhat dot com 2013-05-08 
07:05:37 UTC ---

Which version of GCC are you using?



$ cat head.h

#define HEAD 1



$ cat stdc0.c 

#include head.h

#define STDC0



$ gcc -I. -g3 -save-temps -c stdc0.c 

$ grep __STDC__ stdc0.i 

#define __STDC__ 1



$ gcc -v

Using built-in specs.

COLLECT_GCC=gcc

COLLECT_LTO_WRAPPER=/usr/libexec/gcc/x86_64-redhat-linux/4.7.2/lto-wrapper

Target: x86_64-redhat-linux

Configured with: ../configure --prefix=/usr --mandir=/usr/share/man

--infodir=/usr/share/info --with-bugurl=http://bugzilla.redhat.com/bugzilla

--enable-bootstrap --enable-shared --enable-threads=posix

--enable-checking=release --disable-build-with-cxx

--disable-build-poststage1-with-cxx --with-system-zlib --enable-__cxa_atexit

--disable-libunwind-exceptions --enable-gnu-unique-object

--enable-linker-build-id --with-linker-hash-style=gnu

--enable-languages=c,c++,objc,obj-c++,java,fortran,ada,go,lto --enable-plugin

--enable-initfini-array --enable-java-awt=gtk --disable-dssi

--with-java-home=/usr/lib/jvm/java-1.5.0-gcj-1.5.0.0/jre

--enable-libgcj-multifile --enable-java-maintainer-mode

--with-ecj-jar=/usr/share/java/eclipse-ecj.jar --disable-libjava-multilib

--with-ppl --with-cloog --with-tune=generic --with-arch_32=i686

--build=x86_64-redhat-linux

Thread model: posix

gcc version 4.7.2 20121109 (Red Hat 4.7.2-8) (GCC) 



The above also works with gcc version 4.9.0 20130507 (experimental) (GCC).


[Bug preprocessor/41590] No __STDC__ definition in -g3 -E output on STDC_0_IN_SYSTEM_HEADERS systems

2013-05-08 Thread ro at CeBiTec dot Uni-Bielefeld.DE


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



--- Comment #2 from ro at CeBiTec dot Uni-Bielefeld.DE ro at CeBiTec dot 
Uni-Bielefeld.DE 2013-05-08 09:17:11 UTC ---

 --- Comment #1 from Shakthi Kannan skannan at redhat dot com 2013-05-08 
 07:05:37 UTC ---

 Which version of GCC are you using?



This even affects current mainline.



 The above also works with gcc version 4.9.0 20130507 (experimental) (GCC).



As the PR summary states, this only affects STDC_0_IN_SYSTEM_HEADERS

targets:



ro@apoc 54  grep -r STDC_0_IN_SYSTEM_HEADERS gcc/config

gcc/config/sol2.h:#define STDC_0_IN_SYSTEM_HEADERS 1

gcc/config/sparc/netbsd-elf.h:#undef STDC_0_IN_SYSTEM_HEADERS



I've just verified it again on i386-pc-solaris2.11.



Rainer