• 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: Which SDK is recommended when doing both Mac and iPhone development?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Which SDK is recommended when doing both Mac and iPhone development?


  • Subject: Re: Which SDK is recommended when doing both Mac and iPhone development?
  • From: Jean-Daniel Dupas <email@hidden>
  • Date: Thu, 11 Dec 2008 09:32:37 +0100


Le 11 déc. 08 à 00:16, Jeff Laing a écrit :

I said:
This is most annoying when its common things like [NSString isEqualTo:]
It strikes me that Xcode, compiling for the simulator, really should be
limiting itself to whats available on the actual operating system that
it knows its targetting...

Chris Espinosa [mailto:email@hidden] replied:
The problem is that when building for the Simulator, the actual operating
system it's targeting is the Simulator, which is a hybrid of iPhone frameworks
layered on top of Mac OS X base frameworks. You really truly are executing
Mac OS X's Foundation, CFNetwork, kernel, etc. when running in the
Simulator, and Xcode is behaving exactly correctly.


The point is that the simulator is not the iPhone OS

I'd agree with that if XCode didn't ask me, question 1, whether I was building
an iPhoneOS project or a MacOS project. But that's the very first choice it
requires you to make.


The fact that the Simulator SDK contains methods that are not present on iPhoneOS
looks like a poor design choice to me. Its not a bug because it was designed
that way. That doesn't mean that the design is sensible.


Note, I'm just annoyed by this because I had knocked together a quick app, to
prove to myself that I could do it, multi-hundreds of lines of code, got it
working just fine in the Simulator, went to do a Device build and discovered
that about half the things I was depending on just weren't there, from the
simple [NSString isEqualTo:] to the complex [NSTask ...].

isEqualTo: is a method introduced by foundation to support scriptability. You should never use it to compare objects.
And as AppleScript is not present on the iPhone, there is absolutely no reason to find it.


NSString implements both isEqual: (which is the proper way to compare NSObject)
and isEqualToString: which is a specialized compare function that you can use if you know that you have two strings.


I understand *why* those things aren't present on the device, no problem. And
I understand why they are *available* in the simulator *environment*. But I
don't think its sensible for them to be present in the simulator SDK.
_______________________________________________
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


_______________________________________________ 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
References: 
 >Which SDK is recommended when doing both Mac and iPhone development? (From: "Phil (list)" <email@hidden>)
 >Re: Which SDK is recommended when doing both Mac and iPhone development? (From: Alexander von Below <email@hidden>)
 >Re: Which SDK is recommended when doing both Mac and iPhone development? (From: Phil <email@hidden>)
 >Re: Which SDK is recommended when doing both Mac and iPhone development? (From: Bryan Henry <email@hidden>)
 >RE: Which SDK is recommended when doing both Mac and iPhone development? (From: "Jeff Laing" <email@hidden>)
 >Re: Which SDK is recommended when doing both Mac and iPhone development? (From: Chris Espinosa <email@hidden>)
 >RE: Which SDK is recommended when doing both Mac and iPhone development? (From: "Jeff Laing" <email@hidden>)

  • Prev by Date: Re: Garbage Collection OFF By Default?
  • Next by Date: Re: Newbie Question - #include scope
  • Previous by thread: RE: Which SDK is recommended when doing both Mac and iPhone development?
  • Next by thread: Problem with carbon app and debugger
  • Index(es):
    • Date
    • Thread