public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
* cpp
@ 2002-08-12 11:13 Jeffrey C Knupp
  2002-08-12 11:37 ` cpp Terry Flannery
  0 siblings, 1 reply; 2+ messages in thread
From: Jeffrey C Knupp @ 2002-08-12 11:13 UTC (permalink / raw)
  To: gcc-help

To whoever sees this,
I'm a student at Carnegie Mellon University and I've been using the
preprocessor, cpp, from gcc-3.1. I was wondering if and why when a previously undefined
identifier in an #if is used, there is no warning given. For example, if
the first line of my program is "#if Y" and Y has not been defined, it
will not execute the code (obviously), but it also won't tell me that the
identifier wasn't defined. I was wondering if this was done for a reason.
Hopefully, someone can give me an answer.

Thanks,
Jeff Knupp
Carnegie Mellon University

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

* Re: cpp
  2002-08-12 11:13 cpp Jeffrey C Knupp
@ 2002-08-12 11:37 ` Terry Flannery
  0 siblings, 0 replies; 2+ messages in thread
From: Terry Flannery @ 2002-08-12 11:37 UTC (permalink / raw)
  To: Jeffrey C Knupp, gcc-help

Have a look at the -Wundef flag

Terry

----- Original Message -----
From: "Jeffrey C Knupp" <jknupp@andrew.cmu.edu>
To: <gcc-help@gcc.gnu.org>
Sent: Monday, August 12, 2002 7:13 PM
Subject: cpp


> To whoever sees this,
> I'm a student at Carnegie Mellon University and I've been using the
> preprocessor, cpp, from gcc-3.1. I was wondering if and why when a
previously undefined
> identifier in an #if is used, there is no warning given. For example, if
> the first line of my program is "#if Y" and Y has not been defined, it
> will not execute the code (obviously), but it also won't tell me that the
> identifier wasn't defined. I was wondering if this was done for a reason.
> Hopefully, someone can give me an answer.
>
> Thanks,
> Jeff Knupp
> Carnegie Mellon University
>

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

end of thread, other threads:[~2002-08-12 18:37 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-08-12 11:13 cpp Jeffrey C Knupp
2002-08-12 11:37 ` cpp Terry Flannery

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).