• 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: Variable Number of Parameters in Method
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Variable Number of Parameters in Method


  • Subject: Re: Variable Number of Parameters in Method
  • From: Keary Suska <email@hidden>
  • Date: Wed, 21 Aug 2013 07:42:07 -0600

On Aug 21, 2013, at 3:22 AM, Dave wrote:

> Sorry that snippet was from an existing method that used a nil terminated list, you're right, I can't do that in this case.
>
> I was thinking that it would be easier if everything was an Object, the types I need to support are:
>
> id
> Numeric types, signed/unsigned integers of different lengths and floats.
>
> So I could convert anything that is not an object into an NSNumber and numberWithXXX, which looks like the best way to go!

Or you could pass scalars by reference. e.g. &intValue. All pointers will have the same size and you avoid the NSNumber wrapping overhead.

HTH,

Keary Suska
Esoteritech, Inc.
"Demystifying technology for your home or business"


_______________________________________________

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: 
 >Nav stack creating a bunch of UIImageViews on top of my view (From: Rick Mann <email@hidden>)
 >Variable Number of Parameters in Method (From: Dave <email@hidden>)
 >Re: Variable Number of Parameters in Method (From: "Stephen J. Butler" <email@hidden>)
 >Re: Variable Number of Parameters in Method (From: Dave <email@hidden>)

  • Prev by Date: Re: Variable Number of Parameters in Method
  • Next by Date: Re: -[NSProxy doesNotRecognizeSelector: error
  • Previous by thread: Re: Variable Number of Parameters in Method
  • Next by thread: Re: Variable Number of Parameters in Method
  • Index(es):
    • Date
    • Thread