public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* Why does GCC Preprocessor NOT support such macro?
@ 2009-10-23 14:05 Zhang Lin
  2009-10-23 14:15 ` John Graham
  2009-10-27 22:55 ` Jakub Jelinek
  0 siblings, 2 replies; 6+ messages in thread
From: Zhang Lin @ 2009-10-23 14:05 UTC (permalink / raw)
  To: gcc

Hello,
I have encountered an issue when building ACE with MinGW and GCC 4.4.1
The following macro was not accepted by the preprocessor and it reported such an error: "error: operator '==' has no left operand".

#if !defined (ACE_HAS_NONSTATIC_OBJECT_MANAGER)
# define ACE_HAS_NONSTATIC_OBJECT_MANAGER
#elif (ACE_HAS_NONSTATIC_OBJECT_MANAGER == 0)
# undef ACE_HAS_NONSTATIC_OBJECT_MANAGER
#endif /* ACE_HAS_NONSTATIC_OBJECT_MANAGER */

As I think, since ACE_HAS_NONSTATIC_OBJECT_MANAGER isn't defined, the #elif branch should not be processed.
This macro is accepted by VC7.1 and Sun Studio 12.

Thanks.

Best Regards,
Lin Zhang
2009-10-23

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

end of thread, other threads:[~2009-10-27 20:18 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-10-23 14:05 Why does GCC Preprocessor NOT support such macro? Zhang Lin
2009-10-23 14:15 ` John Graham
2009-10-23 18:21   ` Zhang Lin
2009-10-23 21:56     ` Jean Christophe Beyler
2009-10-23 22:46     ` Andrew Pinski
2009-10-27 22:55 ` Jakub Jelinek

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