-
Notifications
You must be signed in to change notification settings - Fork 12.9k
Closed
Labels
DuplicateAn existing issue was already createdAn existing issue was already created
Description
π Search Terms
"type", "interface", "inference", "Record<string, any[]>"
π Version & Regression Information
- This is the behavior in every version I tried, and I reviewed the FAQ for entries about inferface
β― Playground Link
π» Code
interface A {
key: any[]
}
type B = {
key: any[]
}
type ResultA = A extends Record<string, any[]> ? true : false // false
type ResultB = B extends Record<string, any[]> ? true : false // true
type Test<T extends Record<string, any[]>> = {}
type ResultC = Test<A> // error
π Actual behavior
ResultA differs from ResultB in inference. Additionally, ResultC causes an error.
π Expected behavior
ResultA is the same as ResultB in inference.
Additional information about the issue
No response
Metadata
Metadata
Assignees
Labels
DuplicateAn existing issue was already createdAn existing issue was already created