Xref: utzoo comp.unix.questions:13087 comp.std.c:1087 comp.lang.c:18063 Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!ukma!xanth!mcnc!rti!xyzzy!tiktok!meissner From: meissner@tiktok.dg.com (Michael Meissner) Newsgroups: comp.unix.questions,comp.std.c,comp.lang.c Subject: Re: How can I find out cc or cpp symbols? Keywords: cpp, cc, macros Message-ID: <5459@xyzzy.UUCP> Date: 27 Apr 89 14:47:02 GMT References: <1954@trantor.harris-atd.com> Sender: usenet@xyzzy.UUCP Reply-To: meissner@tiktok.UUCP (Michael Meissner) Followup-To: comp.lang.c Distribution: na Organization: Data General (Languages @ Research Triangle Park, NC.) Lines: 31 In article <1954@trantor.harris-atd.com> bbadger@x102c.harris-atd.com (Bernie Badger Jr.) writes: /* ... */ | What I want is a way to find out *all* the names that are defined. | | I don't believe that the current cpp implementations have a way to do this, | so I am really proposing defining a ``standard option'' which could be | implemented in future cpp's. Actually the cpp that comes with GNU 1.34 has a switch to do what you want, though it is undocumented. If you invoke /usr/local/lib/gcc-cpp with the -d switch, it will do the preprocessing, but only emit the #defines (including the default definitions). Thus, you wound say: /usr/local/lib/gcc-cpp -d