TypeScript/tests/baselines/reference/genericArrayMethods1.errors.txt

6 lines
264 B
Plaintext

==== tests/cases/compiler/genericArrayMethods1.ts (1 errors) ====
var x:string[] = [0,1].slice(0); // this should be an error
~
!!! Type 'number[]' is not assignable to type 'string[]':
!!! Type 'number' is not assignable to type 'string'.