10 lines
No EOL
367 B
Text
10 lines
No EOL
367 B
Text
tests/cases/compiler/nonArrayRestArgs.ts(1,14): error TS2370: A rest parameter must be of an array type.
|
|
|
|
|
|
==== tests/cases/compiler/nonArrayRestArgs.ts (1 errors) ====
|
|
function foo(...rest: number) { // error
|
|
~~~~~~~~~~~~~~~
|
|
!!! error TS2370: A rest parameter must be of an array type.
|
|
var x: string = rest[0];
|
|
return x;
|
|
} |