Closed
Description
Repro
{
"rules": {
"@typescript-eslint/array-type": "error"
}
}
type Unwrap<T> =
T extends Array<infer E> ? E :
T extends ReadonlyArray<infer E> ? E :
/* otherwise */ T
Expected Result
type Unwrap<T> =
T extends (infer E)[] ? E :
T extends ReadonlyArray<infer E> ? E :
/* otherwise */ T
Actual Result
type Unwrap<T> =
T extends infer E[] ? E :
T extends ReadonlyArray<infer E> ? E :
/* otherwise */ T
Additional Info
Nothing in particular.
Versions
package | version |
---|---|
@typescript-eslint/eslint-plugin |
1.1.1 |
@typescript-eslint/parser |
1.1.1 |
TypeScript |
3.2.2 |
ESLint |
5.12.1 |
node |
11.9.0 |
npm |
6.6.0 |