TypeScript/tests/baselines/reference/crashInsourcePropertyIsRelatableToTargetProperty.errors.txt
2014-09-11 16:11:08 -07:00

16 lines
714 B
Plaintext

==== tests/cases/compiler/crashInsourcePropertyIsRelatableToTargetProperty.ts (2 errors) ====
class C {
private x = 1;
}
class D extends C { }
function foo(x: "hi", items: string[]): typeof foo;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
!!! error TS2382: Specialized overload signature is not assignable to any non-specialized signature.
function foo(x: string, items: string[]): typeof foo {
return null;
}
var a: D = foo("hi", []);
~
!!! error TS2322: Type '(x: "hi", items: string[]) => typeof foo' is not assignable to type 'D':
!!! error TS2322: Property 'x' is missing in type '(x: "hi", items: string[]) => typeof foo'.