mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Merge pull request #71821 from slavapestov/inheritance-clause-fixes
Refactor protocol inheritance clauses and existential layout for non-copyable generics
This commit is contained in:
@@ -4389,10 +4389,6 @@ public:
|
||||
/// Type if it `isEscapable` instead of using this.
|
||||
CanBeInvertible::Result canBeEscapable() const;
|
||||
|
||||
/// Determine whether this type has `: <target>` stated explicitly in
|
||||
/// its inheritance clause.
|
||||
bool hasMarking(InvertibleProtocolKind target) const;
|
||||
|
||||
/// Determine whether this type has ~<target>` stated on
|
||||
/// itself, one of its inherited types or `Self` requirements.
|
||||
InverseMarking::Mark hasInverseMarking(InvertibleProtocolKind target) const;
|
||||
@@ -5188,6 +5184,10 @@ public:
|
||||
/// Retrieve the set of protocols inherited from this protocol.
|
||||
ArrayRef<ProtocolDecl *> getInheritedProtocols() const;
|
||||
|
||||
/// Retrieve the transitive closure of the inherited protocols, not including
|
||||
/// this protocol itself.
|
||||
ArrayRef<ProtocolDecl *> getAllInheritedProtocols() const;
|
||||
|
||||
/// Determine whether this protocol has a superclass.
|
||||
bool hasSuperclass() const { return (bool)getSuperclassDecl(); }
|
||||
|
||||
@@ -5255,10 +5255,6 @@ public:
|
||||
/// Determine whether this protocol has ~<target>` stated on
|
||||
/// itself, one of its inherited types or `Self` requirements.
|
||||
InverseMarking::Mark hasInverseMarking(InvertibleProtocolKind target) const;
|
||||
|
||||
/// Determine whether this protocol requires conformance to `IP`, without
|
||||
/// querying a generic signature.
|
||||
bool requiresInvertible(InvertibleProtocolKind ip) const;
|
||||
|
||||
SourceLoc getStartLoc() const { return ProtocolLoc; }
|
||||
SourceRange getSourceRange() const {
|
||||
|
||||
Reference in New Issue
Block a user