mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Extend 'availability' attribute with an unconditional 'deprecated' option.
Allow an unversioned 'deprecated' attribute to specify unconditional
deprecation of an API, e.g.,
@availability(*, deprecated, message="sorry")
func foo() { }
Also support platform-specific deprecation, e.g.,
@availability(iOS, deprecated, message="don't use this on iOS")
func bar() { }
Addresses rdar://problem/20562871.
Swift SVN r27339
This commit is contained in:
@@ -1590,6 +1590,7 @@ void Serializer::writeDeclAttribute(const DeclAttribute *DA) {
|
||||
Out, ScratchRecord, abbrCode,
|
||||
theAttr->isImplicit(),
|
||||
theAttr->isUnconditionallyUnavailable(),
|
||||
theAttr->isUnconditionallyDeprecated(),
|
||||
LIST_VER_TUPLE_PIECES(Introduced),
|
||||
LIST_VER_TUPLE_PIECES(Deprecated),
|
||||
LIST_VER_TUPLE_PIECES(Obsoleted),
|
||||
|
||||
Reference in New Issue
Block a user