• 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: Test for debug vs release
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Test for debug vs release


  • Subject: Re: Test for debug vs release
  • From: Don Quixote de la Mancha <email@hidden>
  • Date: Sun, 21 Mar 2010 11:01:11 -0700

You can also do:

#if !defined( NDEBUG )
    /* Debugging Stuff Goes Here *.
#endif

I don't have an Xcode install handy to actually check (I'm
reinstalling my Mac today), but NDEBUG *should* be defined for release
builds, and not defined for debug builds.

The reason is that the assert macro in <assert.h> disables itself if
NDEBUG is defined.  I am under the impression that the presence or
absence of NDEBUG is specified by the ANSI C definition, but I'm not
completely certain.

Don Quixote
--
Don Quixote de la Mancha
email@hidden
http://www.dulcineatech.com

   Dulcinea Technologies Corporation: Software of Elegance and Beauty.
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Test for debug vs release
      • From: Clark Cox <email@hidden>
References: 
 >Test for debug vs release (From: BareFeet <email@hidden>)
 >Re: Test for debug vs release (From: Gideon King <email@hidden>)
 >Re: Test for debug vs release (From: Jerry Krinock <email@hidden>)

  • Prev by Date: Re: Save As core data question
  • Next by Date: Re: UITable Views and display lags / NSOperation vs NSURLConnection
  • Previous by thread: Re: Test for debug vs release
  • Next by thread: Re: Test for debug vs release
  • Index(es):
    • Date
    • Thread