• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: project builder
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: project builder


  • Subject: Re: project builder
  • From: Richard Dobson <email@hidden>
  • Date: Wed, 20 Aug 2003 16:38:08 +0100

I sympathise: VC++ also accepts #if with a name, even if the name doesn't exist (and even when disabling language extensions). However, at least according to K&R, the preprocessor command #if requries a constant numeric expression (or boolean expression), it is not defined as accepting identifiers as such, so maybe the usage:

#if MAC

~should~ be a syntax error if MAC has not in fact been defined (text substitution being required to furnish a number). And gcc is famous/notorious for rejecting idioms that other compilers tolerate. Whereas the commands
#if defined ...
#ifdef ...
#ifndef ...
will always be legal, with a true or false result.


How about settling for

#ifdef MAC

only three more characters to type, and easy ones at that!

Richard Dobson




Robert Fehse wrote:

...
i always have to write

#if defined MAC

instead of simply

#if MAC

i think i rather try codewarrior.
thx

robert
_______________________________________________
coreaudio-api mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/coreaudio-api
Do not post admin requests to the list. They will be ignored.

References: 
 >Re: project builder (From: "Robert Fehse" <email@hidden>)

  • Prev by Date: Re: Core Audio for a Game Engine
  • Next by Date: dumb idea
  • Previous by thread: Re: project builder
  • Next by thread: Re: project builder
  • Index(es):
    • Date
    • Thread