Accepted baselines.
This commit is contained in:
parent
52a96ac819
commit
74a784c8be
11 changed files with 27 additions and 78 deletions
|
@ -1,8 +1,11 @@
|
||||||
tests/cases/compiler/defaultValueInFunctionTypes.ts(1,9): error TS2371: A parameter initializer is only allowed in a function or constructor implementation.
|
tests/cases/compiler/defaultValueInFunctionTypes.ts(1,9): error TS2371: A parameter initializer is only allowed in a function or constructor implementation.
|
||||||
|
tests/cases/compiler/defaultValueInFunctionTypes.ts(2,11): error TS2371: A parameter initializer is only allowed in a function or constructor implementation.
|
||||||
|
|
||||||
|
|
||||||
==== tests/cases/compiler/defaultValueInFunctionTypes.ts (1 errors) ====
|
==== tests/cases/compiler/defaultValueInFunctionTypes.ts (2 errors) ====
|
||||||
var x: (a: number = 1) => number;
|
var x: (a: number = 1) => number;
|
||||||
~~~~~~~~~~~~~
|
~~~~~~~~~~~~~
|
||||||
!!! error TS2371: A parameter initializer is only allowed in a function or constructor implementation.
|
!!! error TS2371: A parameter initializer is only allowed in a function or constructor implementation.
|
||||||
var y = <(a : string = "") => any>(undefined)
|
var y = <(a : string = "") => any>(undefined)
|
||||||
|
~~~~~~~~~~~~~~~
|
||||||
|
!!! error TS2371: A parameter initializer is only allowed in a function or constructor implementation.
|
|
@ -0,0 +1,11 @@
|
||||||
|
tests/cases/conformance/expressions/typeAssertions/duplicatePropertiesInTypeAssertions01.ts(2,11): error TS2300: Duplicate identifier 'a'.
|
||||||
|
tests/cases/conformance/expressions/typeAssertions/duplicatePropertiesInTypeAssertions01.ts(2,22): error TS2300: Duplicate identifier 'a'.
|
||||||
|
|
||||||
|
|
||||||
|
==== tests/cases/conformance/expressions/typeAssertions/duplicatePropertiesInTypeAssertions01.ts (2 errors) ====
|
||||||
|
|
||||||
|
let x = <{a: number; a: number}>{};
|
||||||
|
~
|
||||||
|
!!! error TS2300: Duplicate identifier 'a'.
|
||||||
|
~
|
||||||
|
!!! error TS2300: Duplicate identifier 'a'.
|
|
@ -1,7 +0,0 @@
|
||||||
=== tests/cases/conformance/expressions/typeAssertions/duplicatePropertiesInTypeAssertions01.ts ===
|
|
||||||
|
|
||||||
let x = <{a: number; a: number}>{};
|
|
||||||
>x : Symbol(x, Decl(duplicatePropertiesInTypeAssertions01.ts, 1, 3))
|
|
||||||
>a : Symbol(a, Decl(duplicatePropertiesInTypeAssertions01.ts, 1, 10), Decl(duplicatePropertiesInTypeAssertions01.ts, 1, 20))
|
|
||||||
>a : Symbol(a, Decl(duplicatePropertiesInTypeAssertions01.ts, 1, 10), Decl(duplicatePropertiesInTypeAssertions01.ts, 1, 20))
|
|
||||||
|
|
|
@ -1,9 +0,0 @@
|
||||||
=== tests/cases/conformance/expressions/typeAssertions/duplicatePropertiesInTypeAssertions01.ts ===
|
|
||||||
|
|
||||||
let x = <{a: number; a: number}>{};
|
|
||||||
>x : { a: number; }
|
|
||||||
><{a: number; a: number}>{} : { a: number; }
|
|
||||||
>a : number
|
|
||||||
>a : number
|
|
||||||
>{} : {}
|
|
||||||
|
|
|
@ -0,0 +1,11 @@
|
||||||
|
tests/cases/conformance/expressions/typeAssertions/duplicatePropertiesInTypeAssertions02.ts(2,16): error TS2300: Duplicate identifier 'a'.
|
||||||
|
tests/cases/conformance/expressions/typeAssertions/duplicatePropertiesInTypeAssertions02.ts(2,27): error TS2300: Duplicate identifier 'a'.
|
||||||
|
|
||||||
|
|
||||||
|
==== tests/cases/conformance/expressions/typeAssertions/duplicatePropertiesInTypeAssertions02.ts (2 errors) ====
|
||||||
|
|
||||||
|
let x = {} as {a: number; a: number};
|
||||||
|
~
|
||||||
|
!!! error TS2300: Duplicate identifier 'a'.
|
||||||
|
~
|
||||||
|
!!! error TS2300: Duplicate identifier 'a'.
|
|
@ -1,7 +0,0 @@
|
||||||
=== tests/cases/conformance/expressions/typeAssertions/duplicatePropertiesInTypeAssertions02.ts ===
|
|
||||||
|
|
||||||
let x = {} as {a: number; a: number};
|
|
||||||
>x : Symbol(x, Decl(duplicatePropertiesInTypeAssertions02.ts, 1, 3))
|
|
||||||
>a : Symbol(a, Decl(duplicatePropertiesInTypeAssertions02.ts, 1, 15), Decl(duplicatePropertiesInTypeAssertions02.ts, 1, 25))
|
|
||||||
>a : Symbol(a, Decl(duplicatePropertiesInTypeAssertions02.ts, 1, 15), Decl(duplicatePropertiesInTypeAssertions02.ts, 1, 25))
|
|
||||||
|
|
|
@ -1,9 +0,0 @@
|
||||||
=== tests/cases/conformance/expressions/typeAssertions/duplicatePropertiesInTypeAssertions02.ts ===
|
|
||||||
|
|
||||||
let x = {} as {a: number; a: number};
|
|
||||||
>x : { a: number; }
|
|
||||||
>{} as {a: number; a: number} : { a: number; }
|
|
||||||
>{} : {}
|
|
||||||
>a : number
|
|
||||||
>a : number
|
|
||||||
|
|
|
@ -1,9 +0,0 @@
|
||||||
=== tests/cases/conformance/types/tuple/emptyTuples/emptyTuplesTypeAssertion01.ts ===
|
|
||||||
|
|
||||||
let x = <[]>[];
|
|
||||||
>x : Symbol(x, Decl(emptyTuplesTypeAssertion01.ts, 1, 3))
|
|
||||||
|
|
||||||
let y = x[0];
|
|
||||||
>y : Symbol(y, Decl(emptyTuplesTypeAssertion01.ts, 2, 3))
|
|
||||||
>x : Symbol(x, Decl(emptyTuplesTypeAssertion01.ts, 1, 3))
|
|
||||||
|
|
|
@ -1,13 +0,0 @@
|
||||||
=== tests/cases/conformance/types/tuple/emptyTuples/emptyTuplesTypeAssertion01.ts ===
|
|
||||||
|
|
||||||
let x = <[]>[];
|
|
||||||
>x : []
|
|
||||||
><[]>[] : []
|
|
||||||
>[] : undefined[]
|
|
||||||
|
|
||||||
let y = x[0];
|
|
||||||
>y : never
|
|
||||||
>x[0] : never
|
|
||||||
>x : []
|
|
||||||
>0 : number
|
|
||||||
|
|
|
@ -1,9 +0,0 @@
|
||||||
=== tests/cases/conformance/types/tuple/emptyTuples/emptyTuplesTypeAssertion02.ts ===
|
|
||||||
|
|
||||||
let x = [] as [];
|
|
||||||
>x : Symbol(x, Decl(emptyTuplesTypeAssertion02.ts, 1, 3))
|
|
||||||
|
|
||||||
let y = x[0];
|
|
||||||
>y : Symbol(y, Decl(emptyTuplesTypeAssertion02.ts, 2, 3))
|
|
||||||
>x : Symbol(x, Decl(emptyTuplesTypeAssertion02.ts, 1, 3))
|
|
||||||
|
|
|
@ -1,13 +0,0 @@
|
||||||
=== tests/cases/conformance/types/tuple/emptyTuples/emptyTuplesTypeAssertion02.ts ===
|
|
||||||
|
|
||||||
let x = [] as [];
|
|
||||||
>x : []
|
|
||||||
>[] as [] : []
|
|
||||||
>[] : undefined[]
|
|
||||||
|
|
||||||
let y = x[0];
|
|
||||||
>y : never
|
|
||||||
>x[0] : never
|
|
||||||
>x : []
|
|
||||||
>0 : number
|
|
||||||
|
|
Loading…
Reference in a new issue