Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

As many of you already know Apple released a new OS last week so I installed it on my system to see if the project I'm working on works. Well, absolutely nothing works.

There are a lot of deprecated methods so I would like some advice on how to tackle updating your code so it is compatible with the new platform.

share|improve this question

closed as too broad by gnat, Bart van Ingen Schenau, Ixrec, Dan Pichelman, GlenH7 Jan 18 at 23:19

There are either too many possible answers, or good answers would be too long for this format. Please add details to narrow the answer set or to isolate an issue that can be answered in a few paragraphs.If this question can be reworded to fit the rules in the help center, please edit the question.

What do you mean by "absolutely nothing works"? – gnasher729 Jan 18 at 14:45
up vote 5 down vote accepted

A deprecated method doesn't normally just stop working; Apple are just indicating that the method is no longer the preferred way of doing things and that it might go away in a future release. Often the documentation will describe the replacement, which might be a different method (as was the case when the -[NSString cString]-style methods were deprecated in favour of methods that explicitly request a particular character encoding), or is sometimes a completely different approach (as with AuthorizationExecuteWithPrivileges(), which you should replace with Not Doing It Like That™).

Other sources of information on migrating away from deprecated API include the WWDC videos and Apple's programming guides, which offer a more high-level description of the frameworks so explain how Apple currently think they should be used. Then you could ask on stack overflow or Apple's developer forums. Finally, there's the option of buying a developer tech support incident from them and getting their engineers to suggest an alternative.

Each part of your code that touches deprecated API will need updating sooner or later, because the writing's on the wall for the deprecated methods. This is a great time to take a look at those classes affected, and ask yourself whether you just need to update how they interact with the system or whether the whole class could be approached in a better way. If you need to make changes, you may as well make the product better while you're in there.

share|improve this answer
Thx this is definitely a start – Samantha Catania Jul 27 '11 at 15:10

Not the answer you're looking for? Browse other questions tagged or ask your own question.