Skip to content

Commit 532e048

Browse files
committed
AST: Remove DependentMemberType::substRootParam()
1 parent fd568e3 commit 532e048

File tree

2 files changed

+0
-19
lines changed

2 files changed

+0
-19
lines changed

include/swift/AST/Types.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7170,11 +7170,6 @@ class DependentMemberType : public TypeBase {
71707170
Type substBaseType(Type base, LookupConformanceFn lookupConformance,
71717171
SubstOptions options);
71727172

7173-
/// Substitute the root generic type, looking up the chain of associated types.
7174-
/// Returns null if the member could not be found in the new root.
7175-
Type substRootParam(Type newRoot, LookupConformanceFn lookupConformance,
7176-
SubstOptions options);
7177-
71787173
// Implement isa/cast/dyncast/etc.
71797174
static bool classof(const TypeBase *T) {
71807175
return T->getKind() == TypeKind::DependentMember;

lib/AST/TypeSubstitution.cpp

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -282,20 +282,6 @@ Type DependentMemberType::substBaseType(Type substBase,
282282
/*level=*/0);
283283
}
284284

285-
Type DependentMemberType::substRootParam(Type newRoot,
286-
LookupConformanceFn lookupConformance,
287-
SubstOptions options) {
288-
auto base = getBase();
289-
if (base->is<GenericTypeParamType>()) {
290-
return substBaseType(newRoot, lookupConformance, options);
291-
}
292-
if (auto depMem = base->getAs<DependentMemberType>()) {
293-
return substBaseType(depMem->substRootParam(newRoot, lookupConformance, options),
294-
lookupConformance, options);
295-
}
296-
return Type();
297-
}
298-
299285
static Type substGenericFunctionType(GenericFunctionType *genericFnType,
300286
InFlightSubstitution &IFS) {
301287
// Substitute into the function type (without generic signature).

0 commit comments

Comments
 (0)