• 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: Suppressing variable hiding warning in Xcode
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Suppressing variable hiding warning in Xcode


  • Subject: Re: Suppressing variable hiding warning in Xcode
  • From: Graham Cox <email@hidden>
  • Date: Mon, 6 Apr 2009 15:34:22 +1000


On 06/04/2009, at 11:06 AM, Bill Bumgarner wrote:

2. How do you get Xcode to not produce this warning?

Don't. You'll thank yourself for not doing so after spending a few hours wondering why an iVar didn't get updated only to find that a parameter hid the iVar.


Given that good advice however, Apple really should ensure that legitimate code doesn't gratuitously throw this warning.

For example:

var = MIN( MAX( x, y ), z );

will emit this warning for variable '_a' because both macros MIN and MAX use the same local var name internally.

--Graham


_______________________________________________

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: 
 >Suppressing variable hiding warning in Xcode (From: Brad O'Hearne <email@hidden>)
 >Re: Suppressing variable hiding warning in Xcode (From: Bill Bumgarner <email@hidden>)

  • Prev by Date: Re: Need localization-proof method of transporting dates.
  • Next by Date: "Word Wrap" and "Character Wrap" in NSTextField
  • Previous by thread: Re: Suppressing variable hiding warning in Xcode
  • Next by thread: Accessing internal lock for atomic properties
  • Index(es):
    • Date
    • Thread