• 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
returning from within @synchronized results in warnings
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

returning from within @synchronized results in warnings


  • Subject: returning from within @synchronized results in warnings
  • From: "Karan, Cem (Civ, ARL/CISD)" <email@hidden>
  • Date: Wed, 12 Aug 2009 08:20:48 -0400
  • Thread-topic: returning from within @synchronized results in warnings

Note that although I mention the iPhone below, this is an Xcode question, not an iPhone question.

I have a bunch of accessors that I define for properties that are something like the following:

- (NSString *)name
{
	@synchronized(self)
	{
		return [[name retain] autorelease];
	}
}

From what I've read, this is correct Objective-C 2.0 syntax, but I keep getting compile warnings like the following:

'warning: control reaches end of non-void function'.

This only happens when I'm compiling for the iPhone simulator, and not for the iPhone itself.  Has anyone else seen this? Since this doesn't happen when I compile to the iPhone, I don't really care, except that I'm concerned it may affect my testing...

I'm running Xcode 3.1.2, and targetting iPhone OS 2.2.1 if that helps.

Thanks,
Cem Karan
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: returning from within @synchronized results in warnings
      • From: Paul Summermatter <email@hidden>
  • Prev by Date: Re: [Q] Editing CFBundleDisplayName & CFBundleName & Kicking the finder
  • Next by Date: Re: returning from within @synchronized results in warnings
  • Previous by thread: Coaxing pbxcp into Preserving Symbolic Links
  • Next by thread: Re: returning from within @synchronized results in warnings
  • Index(es):
    • Date
    • Thread