-
Notifications
You must be signed in to change notification settings - Fork 90
Closed
Description
Since v7.0.3 Typescript errors when checking the library definition files:
One tiny thing: Now `tsc` shows the following errors:
```node_modules/.pnpm/[email protected]/node_modules/runtypes/script/Runtype.d.ts:73:75 - error TS2677: A type predicate's type must be assignable to its parameter's type.
Type 'Validated<T, U>' is not assignable to type 'IsGeneric<this> extends true ? U : Maybe<T, U>'.
Type 'T | (T & U)' is not assignable to type 'IsGeneric<this> extends true ? U : Maybe<T, U>'.
Type 'T' is not assignable to type 'IsGeneric<this> extends true ? U : Maybe<T, U>'.
73 guard<U = T>(x: IsGeneric<this> extends true ? U : Maybe<T, U>): x is Validated<T, U>;
~~~~~~~~~~~~~~~
node_modules/.pnpm/[email protected]/node_modules/runtypes/script/Runtype.d.ts:77:84 - error TS2677: A type predicate's type must be assignable to its parameter's type.
Type 'Validated<T, U>' is not assignable to type 'IsGeneric<this> extends true ? U : Maybe<T, U>'.
Type 'T | (T & U)' is not assignable to type 'IsGeneric<this> extends true ? U : Maybe<T, U>'.
Type 'T' is not assignable to type 'IsGeneric<this> extends true ? U : Maybe<T, U>'.
77 assert<U = T>(x: IsGeneric<this> extends true ? U : Maybe<T, U>): asserts x is Validated<T, U>;
~~~~~~~~~~~~~~~
It’s easy to work around this with skipLibCheck: true though.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels