Sema: fix for 61440 (lib/AST/GenericEnvironment) no generic environment provided for type with type parameter

This commit is contained in:
jreference
2023-04-26 21:29:02 +08:00
parent 6aaccf0207
commit e18b40b743
2 changed files with 47 additions and 3 deletions

View File

@@ -2575,9 +2575,9 @@ static bool fixItOverrideDeclarationTypesImpl(
});
}
auto resultType = subscript->getDeclContext()->mapTypeIntoContext(
subscript->getElementInterfaceType());
auto baseResultType = baseSubscript->getDeclContext()->mapTypeIntoContext(
auto resultType =
subscript->mapTypeIntoContext(subscript->getElementInterfaceType());
auto baseResultType = baseSubscript->mapTypeIntoContext(
baseSubscript->getElementInterfaceType());
fixedAny |= checkType(resultType, ParamDecl::Specifier::Default,
baseResultType, ParamDecl::Specifier::Default,