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

16 lines
783 B
Plaintext

tests/cases/compiler/functionAndInterfaceWithSeparateErrors.ts(1,10): error TS2394: Overload signature is not compatible with function implementation.
tests/cases/compiler/functionAndInterfaceWithSeparateErrors.ts(6,5): error TS2411: Property 'prop' of type 'number' is not assignable to string index type 'string'.
==== tests/cases/compiler/functionAndInterfaceWithSeparateErrors.ts (2 errors) ====
function Foo(s: string);
~~~
!!! error TS2394: Overload signature is not compatible with function implementation.
function Foo(n: number) { }
interface Foo {
[s: string]: string;
prop: number;
~~~~~~~~~~~~~
!!! error TS2411: Property 'prop' of type 'number' is not assignable to string index type 'string'.
}