-
Notifications
You must be signed in to change notification settings - Fork 12.9k
Closed as not planned
Labels
Design LimitationConstraints of the existing architecture prevent this from being fixedConstraints of the existing architecture prevent this from being fixed
Description
π Search Terms
Type alias circularly references itself (5.4 regression)
π Version & Regression Information
- This changed between versions 5.3.3 and 5.4.5
β― Playground Link
π» Code
type BooleanPaths<T> = string &
{
[K in keyof T]: T[K] extends boolean
? K
: T[K] extends object
? K extends number | string
? `${K}.${BooleanPaths<T[K]>}`
: never
: never;
}[keyof T];
π Actual behavior
This code fails with two errors:
Type alias 'BooleanPaths' circularly references itself.
Type 'BooleanPaths' is not generic.
π Expected behavior
The compilation should pass, as it has in previous versions.
Additional information about the issue
No response
Metadata
Metadata
Assignees
Labels
Design LimitationConstraints of the existing architecture prevent this from being fixedConstraints of the existing architecture prevent this from being fixed