Skip to content

Commit aacb4d4

Browse files
committed
Swift AST: add Type.hasDynamicSelf
1 parent f52f491 commit aacb4d4

File tree

3 files changed

+6
-0
lines changed

3 files changed

+6
-0
lines changed

SwiftCompilerSources/Sources/AST/Type.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -180,6 +180,7 @@ extension TypeProperties {
180180
public var hasArchetype: Bool { rawType.bridged.hasArchetype() }
181181
public var hasTypeParameter: Bool { rawType.bridged.hasTypeParameter() }
182182
public var hasLocalArchetype: Bool { rawType.bridged.hasLocalArchetype() }
183+
public var hasDynamicSelf: Bool { rawType.bridged.hasDynamicSelf() }
183184
public var isEscapable: Bool { rawType.bridged.isEscapable() }
184185
public var isNoEscape: Bool { rawType.bridged.isNoEscape() }
185186
public var isBuiltinType: Bool { rawType.bridged.isBuiltinType() }

include/swift/AST/ASTBridging.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3077,6 +3077,7 @@ struct BridgedASTType {
30773077
BRIDGED_INLINE bool isGenericAtAnyLevel() const;
30783078
BRIDGED_INLINE bool hasTypeParameter() const;
30793079
BRIDGED_INLINE bool hasLocalArchetype() const;
3080+
BRIDGED_INLINE bool hasDynamicSelf() const;
30803081
BRIDGED_INLINE bool isArchetype() const;
30813082
BRIDGED_INLINE bool archetypeRequiresClass() const;
30823083
BRIDGED_INLINE bool isExistentialArchetype() const;

include/swift/AST/ASTBridgingImpl.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -436,6 +436,10 @@ bool BridgedASTType::hasLocalArchetype() const {
436436
return unbridged()->hasLocalArchetype();
437437
}
438438

439+
bool BridgedASTType::hasDynamicSelf() const {
440+
return unbridged()->hasDynamicSelfType();
441+
}
442+
439443
bool BridgedASTType::isArchetype() const {
440444
return unbridged()->is<swift::ArchetypeType>();
441445
}

0 commit comments

Comments
 (0)