• 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: Deprecated method documentation
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Deprecated method documentation


  • Subject: Re: Deprecated method documentation
  • From: Fritz Anderson <email@hidden>
  • Date: Thu, 13 Nov 2003 09:05:47 -0600

On 12 Nov 2003, at 4:23 AM, Patrick Machielse wrote:

Why hasn't 'deprecation support' been implemented in the compiler, again
like in Java. Why not let the compiler warn us about deprecated methods in
the first place? (we would have noticed the depracation of
stringWithCString: in Jaguar, I too found out by accident...)

Because Objective-C is a dynamically-typed language. NSString may deprecate the cString message, but MyOwnClass may have a message named cString that is still perfectly valid. The recipient of a cString message may have a compile-time type of id, referring to an NSString, a MyOwnClass, an object that doesn't understand cString at all, or nil. An Objective-C compiler would have no way in principle to distinguish deprecated uses from nondeprecated.

-- F
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: Deprecated method documentation
      • From: Patrick Machielse <email@hidden>
References: 
 >Re: Deprecated method documentation (From: Patrick Machielse <email@hidden>)

  • Prev by Date: Re: looking for correct way to trap for option key
  • Next by Date: NSTask...Whois
  • Previous by thread: Re: Deprecated method documentation
  • Next by thread: Re: Deprecated method documentation
  • Index(es):
    • Date
    • Thread