• 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: NSDecimalNumber nil parameter to -decimalNumberByAdding: causes Mach exception EXC_BAD_ACCESS
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSDecimalNumber nil parameter to -decimalNumberByAdding: causes Mach exception EXC_BAD_ACCESS


  • Subject: Re: NSDecimalNumber nil parameter to -decimalNumberByAdding: causes Mach exception EXC_BAD_ACCESS
  • From: Kyle Sluder <email@hidden>
  • Date: Mon, 13 Apr 2009 17:31:45 -0400

On Mon, Apr 13, 2009 at 5:29 PM, email@hidden
<email@hidden> wrote:
> Whatever way you slice it, bug or not, this is fairly toxic behaviour.

You can't dereference a null pointer, and you can't divide by zero.
Must every possible occurrence of these be marked?

nil is a very special value.  Sometimes the API attaches a meaning to
it -- for example, "pass nil to specify no options."  Other times, the
API expects you to have an object on hand.  I wouldn't complain if all
I got were strange looks when I asked you to add 3 + Banana.

--Kyle Sluder
_______________________________________________

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

References: 
 >NSDecimalNumber nil parameter to -decimalNumberByAdding: causes Mach exception EXC_BAD_ACCESS (From: "email@hidden" <email@hidden>)
 >Re: NSDecimalNumber nil parameter to -decimalNumberByAdding: causes Mach exception EXC_BAD_ACCESS (From: Kyle Sluder <email@hidden>)
 >Re: NSDecimalNumber nil parameter to -decimalNumberByAdding: causes Mach exception EXC_BAD_ACCESS (From: "email@hidden" <email@hidden>)

  • Prev by Date: Re: typeFromFileExtension in Leopard SDK
  • Next by Date: Re: Dynamically getting the type of ivars
  • Previous by thread: Re: NSDecimalNumber nil parameter to -decimalNumberByAdding: causes Mach exception EXC_BAD_ACCESS
  • Next by thread: Re: NSDecimalNumber nil parameter to -decimalNumberByAdding: causes Mach exception EXC_BAD_ACCESS
  • Index(es):
    • Date
    • Thread