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 preprocessor/25717] New: -dM does not list all defined macros (in particular, __STDC__)


The -dM option is documented to provide a complete list of all defined macros,
including all predefined macros, however the list is incomplete. In particular,
the following will not list __STDC__ even though it is defined:

   touch test.h; gcc -dM test.h

If you modify test.h to include:

   #ifdef __STDC__
      #error __STDC__ is defined
   #endif

The compilation will result in an error


-- 
           Summary: -dM does not list all defined macros (in particular,
                    __STDC__)
           Product: gcc
           Version: 3.4.3
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: preprocessor
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: shaun4477 at gmail dot com
 GCC build triplet: ia64-hp-hpux11.23
  GCC host triplet: ia64-hp-hpux11.23
GCC target triplet: ia64-hp-hpux11.23


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



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