Baseline update

This commit is contained in:
Ryan Cavanaugh
2015-07-22 09:41:53 -07:00
parent 06f766ce44
commit e05a81cb3d
6 changed files with 138 additions and 138 deletions
@@ -1,47 +0,0 @@
=== tests/cases/conformance/jsx/react.d.ts ===
declare module JSX {
>JSX : Symbol(JSX, Decl(react.d.ts, 0, 0))
interface Element { }
>Element : Symbol(Element, Decl(react.d.ts, 1, 20))
interface IntrinsicElements {
>IntrinsicElements : Symbol(IntrinsicElements, Decl(react.d.ts, 2, 22))
}
interface ElementAttributesProperty {
>ElementAttributesProperty : Symbol(ElementAttributesProperty, Decl(react.d.ts, 4, 2))
props;
>props : Symbol(props, Decl(react.d.ts, 5, 38))
}
}
interface Props {
>Props : Symbol(Props, Decl(react.d.ts, 8, 1))
foo: string;
>foo : Symbol(foo, Decl(react.d.ts, 10, 17))
}
=== tests/cases/conformance/jsx/file.tsx ===
export class MyComponent {
>MyComponent : Symbol(MyComponent, Decl(file.tsx, 0, 0))
render() {
>render : Symbol(render, Decl(file.tsx, 0, 26))
}
props: { foo: string; }
>props : Symbol(props, Decl(file.tsx, 2, 3))
>foo : Symbol(foo, Decl(file.tsx, 4, 10))
}
<MyComponent foo="bar" />; // ok
>MyComponent : Symbol(MyComponent, Decl(file.tsx, 0, 0))
>foo : Symbol(unknown)
<MyComponent foo={0} />; // should be an error
>MyComponent : Symbol(MyComponent, Decl(file.tsx, 0, 0))
>foo : Symbol(unknown)
@@ -1,49 +0,0 @@
=== tests/cases/conformance/jsx/react.d.ts ===
declare module JSX {
>JSX : any
interface Element { }
>Element : Element
interface IntrinsicElements {
>IntrinsicElements : IntrinsicElements
}
interface ElementAttributesProperty {
>ElementAttributesProperty : ElementAttributesProperty
props;
>props : any
}
}
interface Props {
>Props : Props
foo: string;
>foo : string
}
=== tests/cases/conformance/jsx/file.tsx ===
export class MyComponent {
>MyComponent : MyComponent
render() {
>render : () => void
}
props: { foo: string; }
>props : { foo: string; }
>foo : string
}
<MyComponent foo="bar" />; // ok
><MyComponent foo="bar" /> : JSX.Element
>MyComponent : typeof MyComponent
>foo : any
<MyComponent foo={0} />; // should be an error
><MyComponent foo={0} /> : JSX.Element
>MyComponent : typeof MyComponent
>foo : any
@@ -1,10 +1,8 @@
tests/cases/conformance/jsx/tsxElementResolution8.tsx(8,2): error TS2604: JSX element type 'Div' does not have any construct or call signatures.
tests/cases/conformance/jsx/tsxElementResolution8.tsx(16,2): error TS2601: The return type of a JSX element constructor must return an object type.
tests/cases/conformance/jsx/tsxElementResolution8.tsx(29,2): error TS2601: The return type of a JSX element constructor must return an object type.
tests/cases/conformance/jsx/tsxElementResolution8.tsx(34,2): error TS2604: JSX element type 'Obj3' does not have any construct or call signatures.
==== tests/cases/conformance/jsx/tsxElementResolution8.tsx (4 errors) ====
==== tests/cases/conformance/jsx/tsxElementResolution8.tsx (2 errors) ====
declare module JSX {
interface Element { }
interface IntrinsicElements { }
@@ -23,8 +21,6 @@ tests/cases/conformance/jsx/tsxElementResolution8.tsx(34,2): error TS2604: JSX e
// Error
function Fnum(): number{ return 42; }
<Fnum />
~~~~
!!! error TS2601: The return type of a JSX element constructor must return an object type.
interface Obj1 {
new(): {};
@@ -38,8 +34,6 @@ tests/cases/conformance/jsx/tsxElementResolution8.tsx(34,2): error TS2604: JSX e
}
var Obj2: Obj2;
<Obj2 />; // Error
~~~~
!!! error TS2601: The return type of a JSX element constructor must return an object type.
interface Obj3 {
}
@@ -1,35 +0,0 @@
tests/cases/conformance/jsx/tsxElementResolution9.tsx(11,2): error TS2601: The return type of a JSX element constructor must return an object type.
tests/cases/conformance/jsx/tsxElementResolution9.tsx(18,2): error TS2601: The return type of a JSX element constructor must return an object type.
==== tests/cases/conformance/jsx/tsxElementResolution9.tsx (2 errors) ====
declare module JSX {
interface Element { }
interface IntrinsicElements { }
}
interface Obj1 {
new(n: string): { x: number };
new(n: number): { y: string };
}
var Obj1: Obj1;
<Obj1 />; // Error, return type is not an object type
~~~~
!!! error TS2601: The return type of a JSX element constructor must return an object type.
interface Obj2 {
(n: string): { x: number };
(n: number): { y: string };
}
var Obj2: Obj2;
<Obj2 />; // Error, return type is not an object type
~~~~
!!! error TS2601: The return type of a JSX element constructor must return an object type.
interface Obj3 {
(n: string): { x: number };
(n: number): { x: number; y: string };
}
var Obj3: Obj3;
<Obj3 x={42} />; // OK
@@ -0,0 +1,67 @@
=== tests/cases/conformance/jsx/tsxElementResolution9.tsx ===
declare module JSX {
>JSX : Symbol(JSX, Decl(tsxElementResolution9.tsx, 0, 0))
interface Element { }
>Element : Symbol(Element, Decl(tsxElementResolution9.tsx, 0, 20))
interface IntrinsicElements { }
>IntrinsicElements : Symbol(IntrinsicElements, Decl(tsxElementResolution9.tsx, 1, 22))
}
interface Obj1 {
>Obj1 : Symbol(Obj1, Decl(tsxElementResolution9.tsx, 3, 1), Decl(tsxElementResolution9.tsx, 9, 3))
new(n: string): { x: number };
>n : Symbol(n, Decl(tsxElementResolution9.tsx, 6, 5))
>x : Symbol(x, Decl(tsxElementResolution9.tsx, 6, 18))
new(n: number): { y: string };
>n : Symbol(n, Decl(tsxElementResolution9.tsx, 7, 5))
>y : Symbol(y, Decl(tsxElementResolution9.tsx, 7, 18))
}
var Obj1: Obj1;
>Obj1 : Symbol(Obj1, Decl(tsxElementResolution9.tsx, 3, 1), Decl(tsxElementResolution9.tsx, 9, 3))
>Obj1 : Symbol(Obj1, Decl(tsxElementResolution9.tsx, 3, 1), Decl(tsxElementResolution9.tsx, 9, 3))
<Obj1 />; // Error, return type is not an object type
>Obj1 : Symbol(Obj1, Decl(tsxElementResolution9.tsx, 3, 1), Decl(tsxElementResolution9.tsx, 9, 3))
interface Obj2 {
>Obj2 : Symbol(Obj2, Decl(tsxElementResolution9.tsx, 10, 9), Decl(tsxElementResolution9.tsx, 16, 3))
(n: string): { x: number };
>n : Symbol(n, Decl(tsxElementResolution9.tsx, 13, 2))
>x : Symbol(x, Decl(tsxElementResolution9.tsx, 13, 15))
(n: number): { y: string };
>n : Symbol(n, Decl(tsxElementResolution9.tsx, 14, 2))
>y : Symbol(y, Decl(tsxElementResolution9.tsx, 14, 15))
}
var Obj2: Obj2;
>Obj2 : Symbol(Obj2, Decl(tsxElementResolution9.tsx, 10, 9), Decl(tsxElementResolution9.tsx, 16, 3))
>Obj2 : Symbol(Obj2, Decl(tsxElementResolution9.tsx, 10, 9), Decl(tsxElementResolution9.tsx, 16, 3))
<Obj2 />; // Error, return type is not an object type
>Obj2 : Symbol(Obj2, Decl(tsxElementResolution9.tsx, 10, 9), Decl(tsxElementResolution9.tsx, 16, 3))
interface Obj3 {
>Obj3 : Symbol(Obj3, Decl(tsxElementResolution9.tsx, 17, 9), Decl(tsxElementResolution9.tsx, 23, 3))
(n: string): { x: number };
>n : Symbol(n, Decl(tsxElementResolution9.tsx, 20, 2))
>x : Symbol(x, Decl(tsxElementResolution9.tsx, 20, 15))
(n: number): { x: number; y: string };
>n : Symbol(n, Decl(tsxElementResolution9.tsx, 21, 2))
>x : Symbol(x, Decl(tsxElementResolution9.tsx, 21, 15))
>y : Symbol(y, Decl(tsxElementResolution9.tsx, 21, 26))
}
var Obj3: Obj3;
>Obj3 : Symbol(Obj3, Decl(tsxElementResolution9.tsx, 17, 9), Decl(tsxElementResolution9.tsx, 23, 3))
>Obj3 : Symbol(Obj3, Decl(tsxElementResolution9.tsx, 17, 9), Decl(tsxElementResolution9.tsx, 23, 3))
<Obj3 x={42} />; // OK
>Obj3 : Symbol(Obj3, Decl(tsxElementResolution9.tsx, 17, 9), Decl(tsxElementResolution9.tsx, 23, 3))
>x : Symbol(unknown)
@@ -0,0 +1,70 @@
=== tests/cases/conformance/jsx/tsxElementResolution9.tsx ===
declare module JSX {
>JSX : any
interface Element { }
>Element : Element
interface IntrinsicElements { }
>IntrinsicElements : IntrinsicElements
}
interface Obj1 {
>Obj1 : Obj1
new(n: string): { x: number };
>n : string
>x : number
new(n: number): { y: string };
>n : number
>y : string
}
var Obj1: Obj1;
>Obj1 : Obj1
>Obj1 : Obj1
<Obj1 />; // Error, return type is not an object type
><Obj1 /> : JSX.Element
>Obj1 : Obj1
interface Obj2 {
>Obj2 : Obj2
(n: string): { x: number };
>n : string
>x : number
(n: number): { y: string };
>n : number
>y : string
}
var Obj2: Obj2;
>Obj2 : Obj2
>Obj2 : Obj2
<Obj2 />; // Error, return type is not an object type
><Obj2 /> : JSX.Element
>Obj2 : Obj2
interface Obj3 {
>Obj3 : Obj3
(n: string): { x: number };
>n : string
>x : number
(n: number): { x: number; y: string };
>n : number
>x : number
>y : string
}
var Obj3: Obj3;
>Obj3 : Obj3
>Obj3 : Obj3
<Obj3 x={42} />; // OK
><Obj3 x={42} /> : JSX.Element
>Obj3 : Obj3
>x : any