Identifying deprecated methods

Hi there,

While XCODE can warn you for object c files if the contain a deprecated method (based on sdk) I was wondering if there’s something similar (toggleable) for Asoc?

No, there isn’t. And unfortunately in several cases the ASObjC choice is between deprecated methods and no methods at all.

Thank you.

Any recommendations for best practice of identifying deprecated methods for ASOBJC?

It’s really a question of looking in either the documentation or the .h files. The complication is, as I said, sometimes you need to use deprecated methods. For example, the NSAlert method for showing an alert as a sheet, -beginSheetModalForWindow:modalDelegate:didEndSelector:contextInfo:, is deprecated in favor of -beginSheetModalForWindow:completionHandler:. But you can’t call the latter from ASObjC, so you need to use the deprecated methods.

There can be subtle distinctions on what deprecated means. Mostly, for ASObjC purposes it means use something else if you can.

Thank you.
This is always a great help!