mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
docs: Remove obsolete restriction from LibraryEvolution.rst
This commit is contained in:
@@ -365,8 +365,7 @@ the following changes are permitted:
|
|||||||
an existing property (unless the struct is marked ``@frozen``; see below).
|
an existing property (unless the struct is marked ``@frozen``; see below).
|
||||||
This is effectively the same as modifying the body of a setter.
|
This is effectively the same as modifying the body of a setter.
|
||||||
- Removing any non-ABI-public members, including stored properties.
|
- Removing any non-ABI-public members, including stored properties.
|
||||||
- Adding a conformance to an ABI-public protocol *that was introduced in the
|
- Adding a conformance to an ABI-public protocol (see below about availability).
|
||||||
same release* (see below).
|
|
||||||
- Adding or removing a conformance to a non-ABI-public protocol.
|
- Adding or removing a conformance to a non-ABI-public protocol.
|
||||||
- Adding ``@dynamicCallable`` to the struct.
|
- Adding ``@dynamicCallable`` to the struct.
|
||||||
|
|
||||||
@@ -382,17 +381,9 @@ target for the library is an error.
|
|||||||
It is not safe to add or remove ``mutating`` or ``nonmutating`` from a member
|
It is not safe to add or remove ``mutating`` or ``nonmutating`` from a member
|
||||||
or accessor within a struct.
|
or accessor within a struct.
|
||||||
|
|
||||||
If a conformance is added to a type in version 1.1 of a library, it's important
|
When introducing a new conformance of an existing type to an existing protocol,
|
||||||
that it isn't accessed in version 1.0. This means that it is only safe to add
|
it is important to annotate the conformance with availability. This is achieved
|
||||||
new conformances to ABI-public protocols when the protocol is introduced, and
|
by declaring the conformance on an extension and annotating the extension.
|
||||||
not after. If the protocol comes from a separate module, there is no safe way
|
|
||||||
to conform to it.
|
|
||||||
|
|
||||||
.. admonition:: TODO
|
|
||||||
|
|
||||||
Coming up with a way to do this, either with availability annotations for
|
|
||||||
protocol conformances or a way to emit a fallback copy of the conformance
|
|
||||||
for clients on older library versions to use, is highly desired.
|
|
||||||
|
|
||||||
|
|
||||||
Methods and Initializers
|
Methods and Initializers
|
||||||
|
|||||||
Reference in New Issue
Block a user