public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug preprocessor/48865] New: It would be useful to have a way to check the value of a #define at preprocessing time
@ 2011-05-04  9:02 bero at arklinux dot org
  2011-05-04  9:31 ` [Bug preprocessor/48865] " jakub at gcc dot gnu.org
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: bero at arklinux dot org @ 2011-05-04  9:02 UTC (permalink / raw)
  To: gcc-bugs

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

           Summary: It would be useful to have a way to check the value of
                    a #define at preprocessing time
           Product: gcc
           Version: 4.7.0
            Status: UNCONFIRMED
          Severity: enhancement
          Priority: P3
         Component: preprocessor
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: bero@arklinux.org


When debugging compile failures in huge projects that heavily (ab)use
preprocessor macros, it would be useful to have a way to output the value of a
preprocessor token, e.g. something like

#define XYZ 42 // buried deep inside some header
#warning XYZ is ##XYZ

should say
XYZ is 42

or, better yet:
XYZ is 42 (defined in something.h:123, included from somethingelse.h:456,
included from stillsomethingelse.h:789)


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2011-05-04 17:13 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-05-04  9:02 [Bug preprocessor/48865] New: It would be useful to have a way to check the value of a #define at preprocessing time bero at arklinux dot org
2011-05-04  9:31 ` [Bug preprocessor/48865] " jakub at gcc dot gnu.org
2011-05-04 11:16 ` bero at arklinux dot org
2011-05-04 12:18 ` redi at gcc dot gnu.org
2011-05-04 17:13 ` redi at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).