Skip to content

Commit 69d1048

Browse files
committed
Accept new baselines
1 parent c6ccc5b commit 69d1048

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

tests/baselines/reference/contextuallyTypedParametersWithInitializers.errors.txt

+1-7
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
1-
tests/cases/compiler/contextuallyTypedParametersWithInitializers.ts(8,27): error TS7022: '{ foo = 42 }' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer.
21
tests/cases/compiler/contextuallyTypedParametersWithInitializers.ts(8,29): error TS7031: Binding element 'foo' implicitly has an 'any' type.
32
tests/cases/compiler/contextuallyTypedParametersWithInitializers.ts(14,27): error TS7006: Parameter 'foo' implicitly has an 'any' type.
4-
tests/cases/compiler/contextuallyTypedParametersWithInitializers.ts(27,40): error TS7022: '{ foo = 42 }' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer.
53
tests/cases/compiler/contextuallyTypedParametersWithInitializers.ts(27,42): error TS7031: Binding element 'foo' implicitly has an 'any' type.
64

75

8-
==== tests/cases/compiler/contextuallyTypedParametersWithInitializers.ts (5 errors) ====
6+
==== tests/cases/compiler/contextuallyTypedParametersWithInitializers.ts (3 errors) ====
97
declare function id1<T>(input: T): T;
108
declare function id2<T extends (x: any) => any>(input: T): T;
119
declare function id3<T extends (x: { foo: any }) => any>(input: T): T;
@@ -14,8 +12,6 @@ tests/cases/compiler/contextuallyTypedParametersWithInitializers.ts(27,42): erro
1412

1513
const f10 = function ({ foo = 42 }) { return foo };
1614
const f11 = id1(function ({ foo = 42 }) { return foo }); // Implicit any error
17-
~~~~~~~~~~~~
18-
!!! error TS7022: '{ foo = 42 }' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer.
1915
~~~
2016
!!! error TS7031: Binding element 'foo' implicitly has an 'any' type.
2117
const f12 = id2(function ({ foo = 42 }) { return foo });
@@ -39,8 +35,6 @@ tests/cases/compiler/contextuallyTypedParametersWithInitializers.ts(27,42): erro
3935

4036
const newGetFoo = id(getFoo);
4137
const newGetFoo2 = id(function getFoo ({ foo = 42 }) {
42-
~~~~~~~~~~~~
43-
!!! error TS7022: '{ foo = 42 }' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer.
4438
~~~
4539
!!! error TS7031: Binding element 'foo' implicitly has an 'any' type.
4640
return foo;

0 commit comments

Comments
 (0)