• 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: mouse moved events in NSView?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: mouse moved events in NSView?


  • Subject: Re: mouse moved events in NSView?
  • From: "Louis C. Sacha" <email@hidden>
  • Date: Tue, 11 May 2004 21:24:26 -0700

Hello...

Not that this is really relevant to anything, but

CoreFoundation defines TRUE to be 1, FALSE to be 0.
stdBool.h defines true to be 1, false to be 0. (part of the C99 standard)

The only difference is that objc.h defines YES to be (BOOL)1, and NO to be (BOOL)0.

I don't think the extra cast in the obj-C definitions will make the compiler do anything differently (in terms of storing the value or conversions), and generally anywhere you use any of these will be explicitly typed as BOOL anyway.

So, it's basically a matter of style, and one would hope that any programmer who happens to be reading the code will be capable of figuring out what each of these mean ;)

Louis

Yes, I realize Objective-C uses YES/NO (though I think it's lame for doing so). So far, true/false has also worked fine for me, but I may have only been using true, so thanks for the heads up on false.

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


References: 
 >Re: mouse moved events in NSView? (From: "David Piasecki" <email@hidden>)
 >Re: mouse moved events in NSView? (From: Allan Odgaard <email@hidden>)
 >Re: mouse moved events in NSView? (From: "David Piasecki" <email@hidden>)
 >Re: mouse moved events in NSView? (From: Allan Odgaard <email@hidden>)
 >Re: mouse moved events in NSView? (From: "David Piasecki" <email@hidden>)

  • Prev by Date: Re: GMT offset of Created file date
  • Next by Date: Re: cursor image
  • Previous by thread: Re: mouse moved events in NSView?
  • Next by thread: Building Static Libraries Linked To Frameworks
  • Index(es):
    • Date
    • Thread