TypeScript/tests/baselines/reference/callOverloads1.errors.txt
2014-07-12 17:30:19 -07:00

24 lines
627 B
Plaintext

==== tests/cases/compiler/callOverloads1.ts (3 errors) ====
class Foo {
bar1() { /*WScript.Echo("bar1");*/ }
constructor(x: any) {
// WScript.Echo("Constructor function has executed");
}
}
function Foo(); // error
~~~~~~~~~~~~~~~
!!! Function implementation expected.
~~~
!!! Duplicate identifier 'Foo'.
function F1(s:string);
function F1(a:any) { return a;}
var f1 = new Foo("hey");
f1.bar1();
Foo();
~~~~~
!!! Value of type 'typeof Foo' is not callable. Did you mean to include 'new'?