Skip to content

Commit dffa857

Browse files
authored
Merge pull request swiftlang#21704 from slavapestov/remove-restate-filtering-consumer
Fix a crash by removing the RestateFilteringConsumer
2 parents 66bc166 + 3c0206d commit dffa857

12 files changed

+159
-225
lines changed

lib/AST/Type.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -432,7 +432,7 @@ Type TypeBase::addCurriedSelfType(const DeclContext *dc) {
432432
genericFn->getExtInfo());
433433
}
434434

435-
auto selfTy = dc->getDeclaredInterfaceType();
435+
auto selfTy = dc->getSelfInterfaceType();
436436
auto selfParam = AnyFunctionType::Param(selfTy);
437437
if (sig)
438438
return GenericFunctionType::get(sig, {selfParam}, type);
@@ -853,7 +853,6 @@ Type TypeBase::getMetatypeInstanceType() {
853853
if (auto metaTy = getAs<AnyMetatypeType>())
854854
return metaTy->getInstanceType();
855855

856-
// For mutable value type methods, we need to dig through inout types.
857856
return this;
858857
}
859858

lib/IDE/CodeCompletion.cpp

Lines changed: 23 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -3180,20 +3180,26 @@ class CompletionLookup final : public swift::VisibleDeclConsumer {
31803180
Kind = LookupKind::ValueExpr;
31813181
NeedLeadingDot = !HaveDot;
31823182

3183-
// This is horrible
31843183
ExprType = ExprType->getRValueType();
3184+
assert(!ExprType->hasTypeParameter());
3185+
31853186
this->ExprType = ExprType;
3186-
if (ExprType->hasTypeParameter()) {
3187-
DeclContext *DC = nullptr;
3188-
if (VD)
3189-
DC = VD->getInnermostDeclContext();
3190-
else if (auto NTD = ExprType->getInOutObjectType()
3191-
->getMetatypeInstanceType()->getAnyNominal())
3192-
DC = NTD;
3193-
if (DC)
3194-
ExprType = DC->mapTypeIntoContext(ExprType);
3187+
3188+
// Open existential types, so that lookupVisibleMemberDecls() can properly
3189+
// substitute them.
3190+
bool WasOptional = false;
3191+
if (auto OptionalType = ExprType->getOptionalObjectType()) {
3192+
ExprType = OptionalType;
3193+
WasOptional = true;
31953194
}
31963195

3196+
if (!ExprType->getMetatypeInstanceType()->isAnyObject())
3197+
if (ExprType->isAnyExistentialType())
3198+
ExprType = OpenedArchetypeType::getAny(ExprType);
3199+
3200+
if (WasOptional)
3201+
ExprType = OptionalType::get(ExprType);
3202+
31973203
// Handle special cases
31983204
bool isIUO = VD && VD->getAttrs()
31993205
.hasAttribute<ImplicitlyUnwrappedOptionalAttr>();
@@ -4188,13 +4194,12 @@ class CompletionOverrideLookup : public swift::VisibleDeclConsumer {
41884194
}
41894195
}
41904196

4191-
void addDesignatedInitializers(Type CurrTy) {
4197+
void addDesignatedInitializers(NominalTypeDecl *NTD) {
41924198
if (hasFuncIntroducer || hasVarIntroducer || hasTypealiasIntroducer ||
41934199
hasOverridabilityModifier)
41944200
return;
41954201

4196-
assert(CurrTy);
4197-
const auto *CD = dyn_cast_or_null<ClassDecl>(CurrTy->getAnyNominal());
4202+
const auto *CD = dyn_cast<ClassDecl>(NTD);
41984203
if (!CD)
41994204
return;
42004205
if (!CD->hasSuperclass())
@@ -4211,14 +4216,12 @@ class CompletionOverrideLookup : public swift::VisibleDeclConsumer {
42114216
}
42124217
}
42134218

4214-
void addAssociatedTypes(Type CurrTy) {
4219+
void addAssociatedTypes(NominalTypeDecl *NTD) {
42154220
if (!hasTypealiasIntroducer &&
42164221
(hasFuncIntroducer || hasVarIntroducer || hasInitializerModifier ||
42174222
hasOverride || hasOverridabilityModifier))
42184223
return;
42194224

4220-
NominalTypeDecl *NTD = CurrTy->getAnyNominal();
4221-
42224225
for (auto Conformance : NTD->getAllConformances()) {
42234226
auto Proto = Conformance->getProtocol();
42244227
if (!Proto->isAccessibleFrom(CurrDeclContext))
@@ -4244,13 +4247,14 @@ class CompletionOverrideLookup : public swift::VisibleDeclConsumer {
42444247
if (isa<ProtocolDecl>(CurrDeclContext))
42454248
return;
42464249

4247-
Type CurrTy = CurrDeclContext->getDeclaredTypeInContext();
4250+
Type CurrTy = CurrDeclContext->getSelfTypeInContext();
4251+
auto *NTD = CurrDeclContext->getSelfNominalTypeDecl();
42484252
if (CurrTy && !CurrTy->is<ErrorType>()) {
42494253
lookupVisibleMemberDecls(*this, CurrTy, CurrDeclContext,
42504254
TypeResolver,
42514255
/*includeInstanceMembers=*/false);
4252-
addDesignatedInitializers(CurrTy);
4253-
addAssociatedTypes(CurrTy);
4256+
addDesignatedInitializers(NTD);
4257+
addAssociatedTypes(NTD);
42544258
}
42554259
}
42564260
};

lib/Sema/LookupVisibleDecls.cpp

Lines changed: 12 additions & 115 deletions
Original file line numberDiff line numberDiff line change
@@ -466,92 +466,6 @@ lookupVisibleMemberDeclsImpl(Type BaseTy, VisibleDeclConsumer &Consumer,
466466
GenericSignatureBuilder *GSB,
467467
VisitedSet &Visited);
468468

469-
// Filters out restated declarations from a protocol hierarchy
470-
// or equivalent requirements from protocol composition types.
471-
class RestateFilteringConsumer : public VisibleDeclConsumer {
472-
LazyResolver *resolver;
473-
474-
using FoundDecl = std::pair<ValueDecl*, DeclVisibilityKind>;
475-
using NameAndType = std::pair<DeclName, CanType>;
476-
477-
llvm::DenseMap<DeclName, FoundDecl> foundVars;
478-
llvm::DenseMap<NameAndType, FoundDecl> foundFuncs;
479-
llvm::MapVector<ValueDecl*, DeclVisibilityKind> declsToReport;
480-
481-
template <typename K>
482-
void addDecl(llvm::DenseMap<K, FoundDecl> &Map, K Key, FoundDecl FD) {
483-
// Add the declaration if we haven't found an equivalent yet, otherwise
484-
// replace the equivalent if the found decl has a higher access level.
485-
auto existingDecl = Map.find(Key);
486-
487-
if ((existingDecl == Map.end()) ||
488-
(Map[Key].first->getFormalAccess() < FD.first->getFormalAccess())) {
489-
if (existingDecl != Map.end())
490-
declsToReport.erase({existingDecl->getSecond().first});
491-
Map[Key] = FD;
492-
declsToReport.insert(FD);
493-
}
494-
}
495-
496-
CanType stripSelfRequirementsIfNeeded(ValueDecl *VD,
497-
GenericFunctionType *GFT) const {
498-
// Preserve the generic signature if this is a subscript, which are uncurried,
499-
// or if we have generic params other than Self. Otherwise, use
500-
// the resultType of the curried function type.
501-
// When we keep the generic signature, we remove the requirements
502-
// from Self to make sure they don't prevent us from recognizing restatements.
503-
auto params = GFT->getGenericParams();
504-
if (params.size() == 1 && !isa<SubscriptDecl>(VD)) {
505-
return GFT->getResult()->getCanonicalType();
506-
}
507-
auto Self = VD->getDeclContext()->getSelfInterfaceType();
508-
SmallVector<Requirement, 4> newReqs;
509-
for (auto req: GFT->getRequirements()) {
510-
if (!Self->isEqual(req.getFirstType()))
511-
newReqs.push_back(req);
512-
}
513-
auto newSig = GenericSignature::get(params, newReqs, false);
514-
515-
return GenericFunctionType::get(newSig, GFT->getParams(),
516-
GFT->getResult(), GFT->getExtInfo())
517-
->getCanonicalType();
518-
}
519-
520-
public:
521-
RestateFilteringConsumer(Type baseTy, const DeclContext *DC,
522-
LazyResolver *resolver)
523-
: resolver(resolver) {
524-
assert(DC && baseTy && !baseTy->hasLValueType());
525-
}
526-
527-
void foundDecl(ValueDecl *VD, DeclVisibilityKind Reason) override {
528-
assert(VD);
529-
// If this isn't a protocol context, don't look further into the decl.
530-
if (!isa<ProtocolDecl>(VD->getDeclContext())) {
531-
declsToReport.insert({VD, Reason});
532-
return;
533-
}
534-
if (resolver)
535-
resolver->resolveDeclSignature(VD);
536-
537-
if (!VD->hasInterfaceType()) {
538-
declsToReport.insert({VD, Reason});
539-
return;
540-
}
541-
if (auto GFT = VD->getInterfaceType()->getAs<GenericFunctionType>()) {
542-
auto type = stripSelfRequirementsIfNeeded(VD, GFT);
543-
addDecl(foundFuncs, {VD->getFullName(), type}, {VD, Reason});
544-
return;
545-
}
546-
addDecl(foundVars, VD->getFullName(), {VD, Reason});
547-
}
548-
549-
void feedResultsToConsumer(VisibleDeclConsumer &Consumer) const {
550-
for (const auto entry: declsToReport)
551-
Consumer.foundDecl(entry.first, entry.second);
552-
}
553-
};
554-
555469
static void
556470
lookupVisibleProtocolMemberDecls(Type BaseTy, ProtocolType *PT,
557471
VisibleDeclConsumer &Consumer,
@@ -637,12 +551,11 @@ static void lookupVisibleMemberDeclsImpl(
637551
for (auto Proto : Archetype->getConformsTo())
638552
lookupVisibleProtocolMemberDecls(
639553
BaseTy, Proto->getDeclaredType(), Consumer, CurrDC, LS,
640-
getReasonForSuper(Reason), TypeResolver, GSB, Visited);
554+
Reason, TypeResolver, GSB, Visited);
641555

642556
if (auto superclass = Archetype->getSuperclass())
643557
lookupVisibleMemberDeclsImpl(superclass, Consumer, CurrDC, LS,
644-
getReasonForSuper(Reason), TypeResolver,
645-
GSB, Visited);
558+
Reason, TypeResolver, GSB, Visited);
646559
return;
647560
}
648561

@@ -763,17 +676,6 @@ template <> struct DenseMapInfo<FoundDeclTy> {
763676

764677
namespace {
765678

766-
/// Hack to guess at whether substituting into the type of a declaration will
767-
/// be okay.
768-
/// FIXME: This is awful. We should either have Type::subst() work for
769-
/// GenericFunctionType, or we should kill it outright.
770-
static bool shouldSubstIntoDeclType(Type type) {
771-
auto genericFnType = type->getAs<GenericFunctionType>();
772-
if (!genericFnType) return true;
773-
774-
return false;
775-
}
776-
777679
class OverrideFilteringConsumer : public VisibleDeclConsumer {
778680
public:
779681
std::set<ValueDecl *> AllFoundDecls;
@@ -782,16 +684,12 @@ class OverrideFilteringConsumer : public VisibleDeclConsumer {
782684
Type BaseTy;
783685
const DeclContext *DC;
784686
LazyResolver *TypeResolver;
785-
bool IsTypeLookup = false;
786687

787688
OverrideFilteringConsumer(Type BaseTy, const DeclContext *DC,
788689
LazyResolver *resolver)
789-
: BaseTy(BaseTy), DC(DC), TypeResolver(resolver) {
690+
: BaseTy(BaseTy->getMetatypeInstanceType()),
691+
DC(DC), TypeResolver(resolver) {
790692
assert(!BaseTy->hasLValueType());
791-
if (auto *MetaTy = BaseTy->getAs<AnyMetatypeType>()) {
792-
BaseTy = MetaTy->getInstanceType();
793-
IsTypeLookup = true;
794-
}
795693
assert(DC && BaseTy);
796694
}
797695

@@ -801,7 +699,9 @@ class OverrideFilteringConsumer : public VisibleDeclConsumer {
801699

802700
// If this kind of declaration doesn't participate in overriding, there's
803701
// no filtering to do here.
804-
if (!isa<AbstractFunctionDecl>(VD) && !isa<AbstractStorageDecl>(VD)) {
702+
if (!isa<AbstractFunctionDecl>(VD) &&
703+
!isa<AbstractStorageDecl>(VD) &&
704+
!isa<AssociatedTypeDecl>(VD)) {
805705
DeclsToReport.insert(FoundDeclTy(VD, Reason));
806706
return;
807707
}
@@ -852,7 +752,8 @@ class OverrideFilteringConsumer : public VisibleDeclConsumer {
852752
// don't substitute either.
853753
bool shouldSubst = (!BaseTy->isAnyObject() &&
854754
!BaseTy->hasTypeVariable() &&
855-
BaseTy->getNominalOrBoundGenericNominal() &&
755+
(BaseTy->getNominalOrBoundGenericNominal() ||
756+
BaseTy->is<ArchetypeType>()) &&
856757
VD->getDeclContext()->isTypeContext());
857758
ModuleDecl *M = DC->getParentModule();
858759

@@ -865,8 +766,7 @@ class OverrideFilteringConsumer : public VisibleDeclConsumer {
865766

866767
auto FoundSignature = VD->getOverloadSignature();
867768
auto FoundSignatureType = VD->getOverloadSignatureType();
868-
if (FoundSignatureType && shouldSubst &&
869-
shouldSubstIntoDeclType(FoundSignatureType)) {
769+
if (FoundSignatureType && shouldSubst) {
870770
auto subs = BaseTy->getMemberSubstitutionMap(M, VD);
871771
if (auto CT = FoundSignatureType.subst(subs))
872772
FoundSignatureType = CT->getCanonicalType();
@@ -883,8 +783,7 @@ class OverrideFilteringConsumer : public VisibleDeclConsumer {
883783

884784
auto OtherSignature = OtherVD->getOverloadSignature();
885785
auto OtherSignatureType = OtherVD->getOverloadSignatureType();
886-
if (OtherSignatureType && shouldSubst &&
887-
shouldSubstIntoDeclType(OtherSignatureType)) {
786+
if (OtherSignatureType && shouldSubst) {
888787
auto subs = BaseTy->getMemberSubstitutionMap(M, OtherVD);
889788
if (auto CT = OtherSignatureType.subst(subs))
890789
OtherSignatureType = CT->getCanonicalType();
@@ -926,13 +825,11 @@ static void lookupVisibleMemberDecls(
926825
LookupState LS, DeclVisibilityKind Reason, LazyResolver *TypeResolver,
927826
GenericSignatureBuilder *GSB) {
928827
OverrideFilteringConsumer overrideConsumer(BaseTy, CurrDC, TypeResolver);
929-
RestateFilteringConsumer restateConsumer(BaseTy, CurrDC, TypeResolver);
930828
VisitedSet Visited;
931-
lookupVisibleMemberDeclsImpl(BaseTy, restateConsumer, CurrDC, LS, Reason,
829+
lookupVisibleMemberDeclsImpl(BaseTy, overrideConsumer, CurrDC, LS, Reason,
932830
TypeResolver, GSB, Visited);
933831

934832
// Report the declarations we found to the real consumer.
935-
restateConsumer.feedResultsToConsumer(overrideConsumer);
936833
for (const auto &DeclAndReason : overrideConsumer.DeclsToReport)
937834
Consumer.foundDecl(DeclAndReason.D, DeclAndReason.Reason);
938835
}

test/IDE/complete_from_stdlib.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ func testArchetypeReplacement2<BAR : Equatable>(_ a: [BAR]) {
148148
// PRIVATE_NOMINAL_MEMBERS_6-DAG: Decl[InstanceMethod]/CurrNominal: append({#(newElement): Equatable#})[#Void#]{{; name=.+}}
149149
// PRIVATE_NOMINAL_MEMBERS_6-DAG: Decl[InstanceMethod]/CurrNominal: insert({#(newElement): Equatable#}, {#at: Int#})[#Void#]{{; name=.+}}
150150
// PRIVATE_NOMINAL_MEMBERS_6-DAG: Decl[InstanceMethod]/Super: dropFirst()[#ArraySlice<Equatable>#]{{; name=.+}}
151-
// PRIVATE_NOMINAL_MEMBERS_6-DAG: Decl[InstanceMethod]/Super: dropLast()[#ArraySlice<Equatable>#]{{; name=.+}}
151+
// PRIVATE_NOMINAL_MEMBERS_6-DAG: Decl[InstanceMethod]/Super: dropLast()[#[Equatable]#]{{; name=.+}}
152152
// PRIVATE_NOMINAL_MEMBERS_6-DAG: Decl[InstanceMethod]/Super: enumerated()[#EnumeratedSequence<[Equatable]>#]{{; name=.+}}
153153
// PRIVATE_NOMINAL_MEMBERS_6-DAG: Decl[InstanceMethod]/Super: min({#by: (Equatable, Equatable) throws -> Bool##(Equatable, Equatable) throws -> Bool#})[' rethrows'][#Equatable?#]{{; name=.+}}
154154
// PRIVATE_NOMINAL_MEMBERS_6-DAG: Decl[InstanceMethod]/Super: max({#by: (Equatable, Equatable) throws -> Bool##(Equatable, Equatable) throws -> Bool#})[' rethrows'][#Equatable?#]{{; name=.+}}

test/IDE/complete_members_optional.swift

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,17 +29,17 @@ func optionalMembers1(_ a: HasOptionalMembers1) {
2929
a.#^OPTIONAL_MEMBERS_1^#
3030
}
3131
// OPTIONAL_MEMBERS_1: Begin completions, 3 items
32-
// OPTIONAL_MEMBERS_1-DAG: Decl[InstanceMethod]/CurrNominal: optionalInstanceFunc?()[#Int#]{{; name=.+$}}
33-
// OPTIONAL_MEMBERS_1-DAG: Decl[InstanceVar]/CurrNominal: optionalInstanceProperty[#Int?#]{{; name=.+$}}
32+
// OPTIONAL_MEMBERS_1-DAG: Decl[InstanceMethod]/CurrNominal: optionalInstanceFunc?()[#Int#]{{; name=.+$}}
33+
// OPTIONAL_MEMBERS_1-DAG: Decl[InstanceVar]/CurrNominal: optionalInstanceProperty[#Int?#]{{; name=.+$}}
3434
// OPTIONAL_MEMBERS_1-DAG: Keyword[self]/CurrNominal: self[#HasOptionalMembers1#]; name=self
3535
// OPTIONAL_MEMBERS_1: End completions
3636

3737
func optionalMembers2<T : HasOptionalMembers1>(_ a: T) {
3838
T.#^OPTIONAL_MEMBERS_2^#
3939
}
4040
// OPTIONAL_MEMBERS_2: Begin completions, 4 items
41-
// OPTIONAL_MEMBERS_2-DAG: Decl[InstanceMethod]/Super: optionalInstanceFunc?({#self: HasOptionalMembers1#})[#() -> Int#]{{; name=.+$}}
42-
// OPTIONAL_MEMBERS_2-DAG: Decl[StaticMethod]/Super: optionalClassFunc?()[#Int#]{{; name=.+$}}
43-
// OPTIONAL_MEMBERS_2-DAG: Decl[StaticVar]/Super: optionalClassProperty[#Int?#]{{; name=.+$}}
41+
// OPTIONAL_MEMBERS_2-DAG: Decl[InstanceMethod]/CurrNominal: optionalInstanceFunc?({#self: HasOptionalMembers1#})[#() -> Int#]{{; name=.+$}}
42+
// OPTIONAL_MEMBERS_2-DAG: Decl[StaticMethod]/CurrNominal: optionalClassFunc?()[#Int#]{{; name=.+$}}
43+
// OPTIONAL_MEMBERS_2-DAG: Decl[StaticVar]/CurrNominal: optionalClassProperty[#Int?#]{{; name=.+$}}
4444
// OPTIONAL_MEMBERS_2-DAG: Keyword[self]/CurrNominal: self[#T.Type#]; name=self
4545
// OPTIONAL_MEMBERS_2: End completions

test/IDE/complete_operators.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -279,8 +279,8 @@ func testInfix15<T: P where T.T == S2>() {
279279
T#^INFIX_15^#
280280
}
281281
// INFIX_15: Begin completions, 3 items
282-
// INFIX_15-NEXT: Decl[AssociatedType]/Super: .T; name=T
283-
// INFIX_15-NEXT: Decl[InstanceMethod]/Super: .foo({#self: P#})[#() -> S2#]; name=foo(P)
282+
// INFIX_15-NEXT: Decl[AssociatedType]/CurrNominal: .T; name=T
283+
// INFIX_15-NEXT: Decl[InstanceMethod]/CurrNominal: .foo({#self: P#})[#() -> S2#]; name=foo(P)
284284
// INFIX_15-NEXT: Keyword[self]/CurrNominal: .self[#T.Type#]; name=self
285285
// INFIX_15: End completions
286286

test/IDE/complete_type.swift

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -456,7 +456,7 @@ typealias FooTypealias = Int
456456
//===---
457457

458458
// TYPE_IN_PROTOCOL: Begin completions
459-
// TYPE_IN_PROTOCOL-DAG: Decl[GenericTypeParam]/Super: Self[#Self#]{{; name=.+$}}
459+
// TYPE_IN_PROTOCOL-DAG: Decl[GenericTypeParam]/CurrNominal: Self[#Self#]{{; name=.+$}}
460460
// TYPE_IN_PROTOCOL: End completions
461461

462462
protocol TestSelf1 {
@@ -1013,7 +1013,7 @@ func testTypeIdentifierGeneric1<
10131013
>(a: GenericFoo.#^TYPE_IDENTIFIER_GENERIC_1^#
10141014

10151015
// TYPE_IDENTIFIER_GENERIC_1: Begin completions
1016-
// TYPE_IDENTIFIER_GENERIC_1-NEXT: Decl[AssociatedType]/Super: FooTypeAlias1{{; name=.+$}}
1016+
// TYPE_IDENTIFIER_GENERIC_1-NEXT: Decl[AssociatedType]/CurrNominal: FooTypeAlias1{{; name=.+$}}
10171017
// TYPE_IDENTIFIER_GENERIC_1-NEXT: Keyword/None: Type[#GenericFoo.Type#]
10181018
// TYPE_IDENTIFIER_GENERIC_1-NEXT: End completions
10191019

@@ -1022,8 +1022,8 @@ func testTypeIdentifierGeneric2<
10221022
>(a: GenericFoo.#^TYPE_IDENTIFIER_GENERIC_2^#
10231023

10241024
// TYPE_IDENTIFIER_GENERIC_2: Begin completions
1025-
// TYPE_IDENTIFIER_GENERIC_2-NEXT: Decl[AssociatedType]/Super: BarTypeAlias1{{; name=.+$}}
1026-
// TYPE_IDENTIFIER_GENERIC_2-NEXT: Decl[AssociatedType]/Super: FooTypeAlias1{{; name=.+$}}
1025+
// TYPE_IDENTIFIER_GENERIC_2-NEXT: Decl[AssociatedType]/CurrNominal: BarTypeAlias1{{; name=.+$}}
1026+
// TYPE_IDENTIFIER_GENERIC_2-NEXT: Decl[AssociatedType]/CurrNominal: FooTypeAlias1{{; name=.+$}}
10271027
// TYPE_IDENTIFIER_GENERIC_2-NEXT: Keyword/None: Type[#GenericFoo.Type#]
10281028
// TYPE_IDENTIFIER_GENERIC_2-NEXT: End completions
10291029

test/IDE/complete_type_subscript.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ extension G6 {
100100
subscript(b x: T.#^GEN_EXT_PARAM_6^#) -> Int { return 0 }
101101
subscript(b x: Int) -> T.#^GEN_EXT_RETURN_6^# { return 0 }
102102
}
103-
// GEN_PARAM_6-DAG: Decl[AssociatedType]/Super: Assoc;
103+
// GEN_PARAM_6-DAG: Decl[AssociatedType]/CurrNominal: Assoc;
104104
// GEN_PARAM_6-DAG: Keyword/None: Type[#T.Type#];
105105

106106
// RUN: %target-swift-ide-test -code-completion -source-filename %s -code-completion-token=GENPROTO_PARAM_1 | %FileCheck %s -check-prefix=GENPROTO_1
@@ -116,5 +116,5 @@ extension GP1 {
116116
subscript(b x: I.#^GENPROTO_EXT_PARAM_1^#) -> Int { return 1 }
117117
subscript(b x: Int) -> I.#^GENPROTO_EXT_RETURN_1^# { return 1 }
118118
}
119-
// GENPROTO_1-DAG: Decl[AssociatedType]/Super: Assoc;
119+
// GENPROTO_1-DAG: Decl[AssociatedType]/CurrNominal: Assoc;
120120
// GENPROTO_1-DAG: Keyword/None: Type[#Self.I.Type#];

0 commit comments

Comments
 (0)