File tree Expand file tree Collapse file tree 2 files changed +24
-5
lines changed
validation-test/IDE/crashers_2_fixed Expand file tree Collapse file tree 2 files changed +24
-5
lines changed Original file line number Diff line number Diff line change @@ -445,10 +445,9 @@ Type TypeSubstituter::transformDependentMemberType(DependentMemberType *dependen
445
445
auto conformance = IFS.lookupConformance (origBase, proto, level);
446
446
447
447
auto result = conformance.getTypeWitness (assocType, IFS.getOptions ());
448
- if (result->is <ErrorType>()) {
449
- auto substBase = origBase.subst (IFS);
450
- return DependentMemberType::get (ErrorType::get (substBase), assocType);
451
- }
448
+ if (result->is <ErrorType>())
449
+ return DependentMemberType::get (ErrorType::get (ctx), assocType);
450
+
452
451
return result;
453
452
}
454
453
@@ -1242,4 +1241,4 @@ ProtocolConformanceRef ReplaceExistentialArchetypesWithConcreteTypes::operator()
1242
1241
1243
1242
return subs.lookupConformance (
1244
1243
getInterfaceType (existentialArchetype)->getCanonicalType (), proto);
1245
- }
1244
+ }
Original file line number Diff line number Diff line change
1
+ // RUN: %target-swift-ide-test -code-completion -code-completion-token=COMPLETE -source-filename=%s
2
+
3
+ // https://github.com/swiftlang/swift/pull/82147
4
+
5
+ protocol P {
6
+ associatedtype X
7
+ }
8
+
9
+ struct S < T> {
10
+ init < U, V> ( ) where T == ( U , V ) { }
11
+ }
12
+ extension S : P where T : P {
13
+ typealias X = T . X
14
+ }
15
+
16
+ func foo< T: P , U> ( _: ( ) -> T ) where U == T . X { }
17
+
18
+ foo {
19
+ S ( #^COMPLETE^#)
20
+ }
You can’t perform that action at this time.
0 commit comments