Skip to content

Commit cd399fb

Browse files
Accepted baselines.
1 parent c5c594f commit cd399fb

File tree

3 files changed

+16
-12
lines changed

3 files changed

+16
-12
lines changed

tests/baselines/reference/contextualTypeWithUnionTypeObjectLiteral.errors.txt

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@ tests/cases/conformance/types/union/contextualTypeWithUnionTypeObjectLiteral.ts(
2222
Type 'string | number' is not assignable to type 'number'.
2323
Type 'string' is not assignable to type 'number'.
2424
tests/cases/conformance/types/union/contextualTypeWithUnionTypeObjectLiteral.ts(58,5): error TS2322: Type '(a: string, b: number) => string | number' is not assignable to type '((a: string, b: number) => string) | ((a: string, b: number) => number)'.
25-
Type '(a: string, b: number) => string | number' is not assignable to type '(a: string, b: number) => number'.
26-
Type 'string | number' is not assignable to type 'number'.
27-
Type 'string' is not assignable to type 'number'.
25+
Type '(a: string, b: number) => string | number' is not assignable to type '(a: string, b: number) => string'.
26+
Type 'string | number' is not assignable to type 'string'.
27+
Type 'number' is not assignable to type 'string'.
2828

2929

3030
==== tests/cases/conformance/types/union/contextualTypeWithUnionTypeObjectLiteral.ts (6 errors) ====
@@ -116,8 +116,8 @@ tests/cases/conformance/types/union/contextualTypeWithUnionTypeObjectLiteral.ts(
116116
commonMethodDifferentReturnType: (a, b) => strOrNumber,
117117
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
118118
!!! error TS2322: Type '(a: string, b: number) => string | number' is not assignable to type '((a: string, b: number) => string) | ((a: string, b: number) => number)'.
119-
!!! error TS2322: Type '(a: string, b: number) => string | number' is not assignable to type '(a: string, b: number) => number'.
120-
!!! error TS2322: Type 'string | number' is not assignable to type 'number'.
121-
!!! error TS2322: Type 'string' is not assignable to type 'number'.
119+
!!! error TS2322: Type '(a: string, b: number) => string | number' is not assignable to type '(a: string, b: number) => string'.
120+
!!! error TS2322: Type 'string | number' is not assignable to type 'string'.
121+
!!! error TS2322: Type 'number' is not assignable to type 'string'.
122122
!!! related TS6500 tests/cases/conformance/types/union/contextualTypeWithUnionTypeObjectLiteral.ts:35:5: The expected type comes from property 'commonMethodDifferentReturnType' which is declared here on type 'I11 | I21'
123123
};

tests/baselines/reference/errorsWithCallablesInUnions01.errors.txt

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
tests/cases/compiler/errorsWithCallablesInUnions01.ts(10,12): error TS2322: Type '(x: string) => void' is not assignable to type 'IDirectiveLinkFn<number> | IDirectivePrePost<number>'.
2-
Type '(x: string) => void' has no properties in common with type 'IDirectivePrePost<number>'.
2+
Type '(x: string) => void' is not assignable to type 'IDirectiveLinkFn<number>'.
3+
Types of parameters 'x' and 'scope' are incompatible.
4+
Type 'number' is not assignable to type 'string'.
35

46

57
==== tests/cases/compiler/errorsWithCallablesInUnions01.ts (1 errors) ====
@@ -15,5 +17,7 @@ tests/cases/compiler/errorsWithCallablesInUnions01.ts(10,12): error TS2322: Type
1517
export let blah: IDirectiveLinkFn<number> | IDirectivePrePost<number> = (x: string) => {}
1618
~~~~
1719
!!! error TS2322: Type '(x: string) => void' is not assignable to type 'IDirectiveLinkFn<number> | IDirectivePrePost<number>'.
18-
!!! error TS2322: Type '(x: string) => void' has no properties in common with type 'IDirectivePrePost<number>'.
20+
!!! error TS2322: Type '(x: string) => void' is not assignable to type 'IDirectiveLinkFn<number>'.
21+
!!! error TS2322: Types of parameters 'x' and 'scope' are incompatible.
22+
!!! error TS2322: Type 'number' is not assignable to type 'string'.
1923

tests/baselines/reference/functionExpressionContextualTyping2.errors.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
tests/cases/conformance/expressions/contextualTyping/functionExpressionContextualTyping2.ts(11,1): error TS2322: Type '(foo: number, bar: string) => boolean' is not assignable to type '((n: number, s: string) => number) | ((n: number, s: string) => string)'.
2-
Type '(foo: number, bar: string) => boolean' is not assignable to type '(n: number, s: string) => string'.
3-
Type 'boolean' is not assignable to type 'string'.
2+
Type '(foo: number, bar: string) => boolean' is not assignable to type '(n: number, s: string) => number'.
3+
Type 'boolean' is not assignable to type 'number'.
44

55

66
==== tests/cases/conformance/expressions/contextualTyping/functionExpressionContextualTyping2.ts (1 errors) ====
@@ -17,5 +17,5 @@ tests/cases/conformance/expressions/contextualTyping/functionExpressionContextua
1717
a1 = (foo, bar) => { return true; } // Error
1818
~~
1919
!!! error TS2322: Type '(foo: number, bar: string) => boolean' is not assignable to type '((n: number, s: string) => number) | ((n: number, s: string) => string)'.
20-
!!! error TS2322: Type '(foo: number, bar: string) => boolean' is not assignable to type '(n: number, s: string) => string'.
21-
!!! error TS2322: Type 'boolean' is not assignable to type 'string'.
20+
!!! error TS2322: Type '(foo: number, bar: string) => boolean' is not assignable to type '(n: number, s: string) => number'.
21+
!!! error TS2322: Type 'boolean' is not assignable to type 'number'.

0 commit comments

Comments
 (0)