Skip to content

Commit 6f3b8ca

Browse files
authored
Merge pull request #9978 from ahoppen/pdm-remove-implicit-conversion
Remove implicit conversion from DeclBaseName to Identifier
2 parents 5cda94b + 930ffda commit 6f3b8ca

File tree

3 files changed

+2
-7
lines changed

3 files changed

+2
-7
lines changed

include/swift/AST/Identifier.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -250,11 +250,6 @@ class DeclBaseName {
250250
return Ident.get() < RHS.Ident.get();
251251
}
252252

253-
// TODO: Remove once migration to DeclBaseName has been completed
254-
operator Identifier() {
255-
return getIdentifier();
256-
}
257-
258253
const void *getAsOpaquePointer() const { return Ident.get(); }
259254

260255
static DeclBaseName getFromOpaquePointer(void *P) {

lib/Sema/CSDiag.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7141,7 +7141,7 @@ static bool diagnoseKeyPathComponents(ConstraintSystem *CS, KeyPathExpr *KPE,
71417141
switch (auto kind = component.getKind()) {
71427142
case KeyPathExpr::Component::Kind::UnresolvedProperty: {
71437143
auto componentFullName = component.getUnresolvedDeclName();
7144-
componentName = componentFullName.getBaseName();
7144+
componentName = componentFullName.getBaseIdentifier();
71457145
break;
71467146
}
71477147

lib/Sema/TypeCheckConstraints.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1041,7 +1041,7 @@ TypeExpr *PreCheckExpression::simplifyNestedTypeExpr(UnresolvedDotExpr *UDE) {
10411041
if (!UDE->getName().isSimpleName())
10421042
return nullptr;
10431043

1044-
auto Name = UDE->getName().getBaseName();
1044+
auto Name = UDE->getName().getBaseIdentifier();
10451045
auto NameLoc = UDE->getNameLoc().getBaseNameLoc();
10461046

10471047
// Qualified type lookup with a module base is represented as a DeclRefExpr

0 commit comments

Comments
 (0)