Article View: gnu.gcc.help
Article #49476Re: #define/enum conflict
From: Robert Andrew Ryan
Date: Mon, 24 Jan 1994 21:52
Date: Mon, 24 Jan 1994 21:52
15 lines
1395 bytes
1395 bytes
Excerpts from netnews.gnu.gcc.help: 24-Jan-94 #define/enum conflict Steve Harris@rdxsun38.au (283) > If a #define symbol conflicts with an enum symbol > gcc reports no error unless the #define comes BEFORE > the enum. > When the #define comes after the enum the #define value > seems to take precedence and no compiler warning/error > is given This is standard behavior, the preprocessor (which handles #include, #define, #if, etc...) is completely separate from the compiler. It has no idea about C constructs like types. -Rob
Technical Details
Message-ID:
<0hF4A3C00gjOF5amdb@andrew.cmu.edu>Path:
arc1-ca.pugleaf.net!gmd.de!xlink.net!zib-berlin.de!zrz.TU-Berlin.DE!netmbx.de!Germany.EU.net!EU.net!howland.reston.ans.net!usenet.ins.cwru.edu!magnus.acs.ohio-state.edu!cis.ohio-state.edu!news.sei.cmu.edu!bb3.andrew.cmu.edu!andrew.cmu.edu!rr2b+References:
<9401241924.AA18389@rdxsun38.aud.alcatel.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 11318c,e6aabe672a9e8f53 X-Google-Attributes: gid11318c,public X-Google-ArrivalTime: 1994-01-25 01:13:34 PST Path: arc1-ca.pugleaf.net!gmd.de!xlink.net!zib-berlin.de!zrz.TU-Berlin.DE!netmbx.de!Germany.EU.net!EU.net!howland.reston.ans.net!usenet.ins.cwru.edu!magnus.acs.ohio-state.edu!cis.ohio-state.edu!news.sei.cmu.edu!bb3.andrew.cmu.edu!andrew.cmu.edu!rr2b+ From: Robert Andrew Ryan <rr2b+@andrew.cmu.edu> Newsgroups: gnu.gcc.help Subject: Re: #define/enum conflict Date: Mon, 24 Jan 1994 16:52:03 -0500 Organization: Information Technology Center, Carnegie Mellon, Pittsburgh, PA Lines: 15 Message-ID: <0hF4A3C00gjOF5amdb@andrew.cmu.edu> References: <9401241924.AA18389@rdxsun38.aud.alcatel.com> NNTP-Posting-Host: po2.andrew.cmu.edu In-Reply-To: <9401241924.AA18389@rdxsun38.aud.alcatel.com>