Skip to content

Commit 47d949a

Browse files
committed
Revert "Accept new baselines"
This reverts commit 289ba80.
1 parent 289ba80 commit 47d949a

7 files changed

+266
-155
lines changed

tests/baselines/reference/circularlyConstrainedMappedTypeContainingConditionalNoInfiniteInstantiationDepth.errors.txt

Lines changed: 130 additions & 31 deletions
Large diffs are not rendered by default.

tests/baselines/reference/circularlyConstrainedMappedTypeContainingConditionalNoInfiniteInstantiationDepth.types

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ type ComponentType<P = {}> = ComponentClass<P> | FunctionComponent<P>;
7979
>ComponentType : ComponentType<P>
8080

8181
export type Shared<
82-
>Shared : any
82+
>Shared : Shared<InjectedProps, DecorationTargetProps>
8383

8484
InjectedProps,
8585
DecorationTargetProps extends Shared<InjectedProps, DecorationTargetProps>

tests/baselines/reference/circularlySimplifyingConditionalTypesNoCrash.errors.txt

Lines changed: 0 additions & 81 deletions
This file was deleted.

tests/baselines/reference/circularlySimplifyingConditionalTypesNoCrash.types

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ type Omit<T, K extends keyof T> = Pick<T, Exclude<keyof T, K>>;
33
>Omit : Pick<T, Exclude<keyof T, K>>
44

55
type Shared< // Circularly self constraining type, defered thanks to mapping
6-
>Shared : any
6+
>Shared : Shared<InjectedProps, DecorationTargetProps>
77

88
InjectedProps,
99
DecorationTargetProps extends Shared<InjectedProps, DecorationTargetProps>

tests/baselines/reference/infiniteConstraints.errors.txt

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,14 @@
1-
tests/cases/compiler/infiniteConstraints.ts(3,37): error TS2536: Type '"val"' cannot be used to index type 'Extract<B[Exclude<keyof B, K>], { val: string; }>'.
21
tests/cases/compiler/infiniteConstraints.ts(4,37): error TS2536: Type '"val"' cannot be used to index type 'B[Exclude<keyof B, K>]'.
32
tests/cases/compiler/infiniteConstraints.ts(31,43): error TS2322: Type 'Record<"val", "dup">' is not assignable to type 'never'.
43
tests/cases/compiler/infiniteConstraints.ts(31,63): error TS2322: Type 'Record<"val", "dup">' is not assignable to type 'never'.
54
tests/cases/compiler/infiniteConstraints.ts(36,71): error TS2536: Type '"foo"' cannot be used to index type 'T[keyof T]'.
65
tests/cases/compiler/infiniteConstraints.ts(48,16): error TS2589: Type instantiation is excessively deep and possibly infinite.
76

87

9-
==== tests/cases/compiler/infiniteConstraints.ts (6 errors) ====
8+
==== tests/cases/compiler/infiniteConstraints.ts (5 errors) ====
109
// Both of the following types trigger the recursion limiter in getImmediateBaseConstraint
1110

1211
type T1<B extends { [K in keyof B]: Extract<B[Exclude<keyof B, K>], { val: string }>["val"] }> = B;
13-
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
14-
!!! error TS2536: Type '"val"' cannot be used to index type 'Extract<B[Exclude<keyof B, K>], { val: string; }>'.
1512
type T2<B extends { [K in keyof B]: B[Exclude<keyof B, K>]["val"] }> = B;
1613
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1714
!!! error TS2536: Type '"val"' cannot be used to index type 'B[Exclude<keyof B, K>]'.

0 commit comments

Comments
 (0)