Skip to content

Commit

Permalink
Accept new baselines
Browse files Browse the repository at this point in the history
  • Loading branch information
ahejlsberg committed Feb 19, 2021
1 parent 538b5c8 commit 3d6dbf4
Show file tree
Hide file tree
Showing 4 changed files with 7,025 additions and 6 deletions.
4 changes: 2 additions & 2 deletions tests/baselines/reference/typeParameterLeak.types
Original file line number Diff line number Diff line change
Expand Up @@ -28,15 +28,15 @@ declare const f: BoxFactoryFactory<BoxTypes>;
const b = f({ x: "", y: "" })?.getBox();
>b : Box<{ x: string; }> | Box<{ y: string; }> | undefined
>f({ x: "", y: "" })?.getBox() : Box<{ x: string; }> | Box<{ y: string; }> | undefined
>f({ x: "", y: "" })?.getBox : (() => Box<{ x: string; }>) | (() => Box<{ y: string; }>) | undefined
>f({ x: "", y: "" })?.getBox : (() => Box<{ y: string; }>) | (() => Box<{ x: string; }>) | undefined
>f({ x: "", y: "" }) : BoxFactory<Box<{ x: string; }>> | BoxFactory<Box<{ y: string; }>> | undefined
>f : ((arg: { x: string; }) => BoxFactory<Box<{ x: string; }>> | undefined) | ((arg: { y: string; }) => BoxFactory<Box<{ y: string; }>> | undefined)
>{ x: "", y: "" } : { x: string; y: string; }
>x : string
>"" : ""
>y : string
>"" : ""
>getBox : (() => Box<{ x: string; }>) | (() => Box<{ y: string; }>) | undefined
>getBox : (() => Box<{ y: string; }>) | (() => Box<{ x: string; }>) | undefined

if (b) {
>b : Box<{ x: string; }> | Box<{ y: string; }> | undefined
Expand Down
4 changes: 2 additions & 2 deletions tests/baselines/reference/unionOfClassCalls.types
Original file line number Diff line number Diff line change
Expand Up @@ -211,12 +211,12 @@ declare var a: Bar | Baz;
// note, you must annotate `result` for now
a.doThing().then((result: Bar | Baz) => {
>a.doThing().then((result: Bar | Baz) => { // whatever}) : Promise<void>
>a.doThing().then : (<TResult1 = Bar, TResult2 = never>(onfulfilled?: ((value: Bar) => TResult1 | PromiseLike<TResult1>) | null | undefined, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | null | undefined) => Promise<TResult1 | TResult2>) | (<TResult1 = Baz, TResult2 = never>(onfulfilled?: ((value: Baz) => TResult1 | PromiseLike<TResult1>) | null | undefined, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | null | undefined) => Promise<TResult1 | TResult2>)
>a.doThing().then : (<TResult1 = Baz, TResult2 = never>(onfulfilled?: ((value: Baz) => TResult1 | PromiseLike<TResult1>) | null | undefined, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | null | undefined) => Promise<TResult1 | TResult2>) | (<TResult1 = Bar, TResult2 = never>(onfulfilled?: ((value: Bar) => TResult1 | PromiseLike<TResult1>) | null | undefined, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | null | undefined) => Promise<TResult1 | TResult2>)
>a.doThing() : Promise<Bar> | Promise<Baz>
>a.doThing : (() => Promise<Bar>) | (() => Promise<Baz>)
>a : Bar | Baz
>doThing : (() => Promise<Bar>) | (() => Promise<Baz>)
>then : (<TResult1 = Bar, TResult2 = never>(onfulfilled?: ((value: Bar) => TResult1 | PromiseLike<TResult1>) | null | undefined, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | null | undefined) => Promise<TResult1 | TResult2>) | (<TResult1 = Baz, TResult2 = never>(onfulfilled?: ((value: Baz) => TResult1 | PromiseLike<TResult1>) | null | undefined, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | null | undefined) => Promise<TResult1 | TResult2>)
>then : (<TResult1 = Baz, TResult2 = never>(onfulfilled?: ((value: Baz) => TResult1 | PromiseLike<TResult1>) | null | undefined, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | null | undefined) => Promise<TResult1 | TResult2>) | (<TResult1 = Bar, TResult2 = never>(onfulfilled?: ((value: Bar) => TResult1 | PromiseLike<TResult1>) | null | undefined, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | null | undefined) => Promise<TResult1 | TResult2>)
>(result: Bar | Baz) => { // whatever} : (result: Bar | Baz) => void
>result : Bar | Baz

Expand Down

0 comments on commit 3d6dbf4

Please sign in to comment.