mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-02-14 02:15:12 -06:00
Error on circular constraints in mapped types
This commit is contained in:
parent
2646828198
commit
63387bb5e0
@ -6059,6 +6059,9 @@ namespace ts {
|
||||
type.aliasSymbol = getAliasSymbolForTypeNode(node);
|
||||
type.aliasTypeArguments = getAliasTypeArgumentsForTypeNode(node);
|
||||
links.resolvedType = type;
|
||||
// Eagerly resolve the constraint type which forces an error if the constraint type circularly
|
||||
// references itself through one or more type aliases.
|
||||
getConstraintTypeFromMappedType(type);
|
||||
}
|
||||
return links.resolvedType;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user