File tree Expand file tree Collapse file tree 2 files changed +12
-2
lines changed Expand file tree Collapse file tree 2 files changed +12
-2
lines changed Original file line number Diff line number Diff line change @@ -1504,8 +1504,8 @@ bool IndexSwiftASTWalker::reportExtension(ExtensionDecl *D) {
15041504 if (!startEntity (D, Info, /* IsRef=*/ false ))
15051505 return false ;
15061506
1507- if (! reportRelatedRef (NTD, Loc, /* isImplicit= */ false ,
1508- (SymbolRoleSet)SymbolRole::RelationExtendedBy, D))
1507+ TypeLoc TL (D-> getExtendedTypeRepr (), D-> getExtendedType ());
1508+ if (! reportRelatedTypeRef (TL, (SymbolRoleSet)SymbolRole::RelationExtendedBy, D))
15091509 return false ;
15101510 if (!reportInheritedTypeRefs (D->getInherited (), D))
15111511 return false ;
Original file line number Diff line number Diff line change @@ -499,3 +499,13 @@ protocol WithPrimary<Assoc> {
499499// CHECK: [[@LINE-1]]:18 | type-alias/associated-type/Swift | Assoc | {{.*}} | Def,RelChild | rel: 1
500500// CHECK-NEXT: RelChild | protocol/Swift | WithPrimary | {{.*}}
501501}
502+
503+ struct Root { } // CHECK: [[@LINE]]:8 | struct/Swift | Root | [[Root_USR:.*]] | Def | rel: 0
504+
505+ typealias Alias = Root // CHECK: [[@LINE]]:11 | type-alias/Swift | Alias | [[Alias_USR:.*]] | Def | rel: 0
506+
507+ extension Alias {
508+ // CHECK: [[@LINE-1]]:11 | type-alias/Swift | Alias | [[Alias_USR]] | Ref | rel: 0
509+ // CHECK: [[@LINE-2]]:11 | struct/Swift | Root | [[Root_USR]] | Ref,Impl,RelExt | rel: 1
510+ func empty( ) { }
511+ }
You can’t perform that action at this time.
0 commit comments