mirror of
https://github.com/hanzoai/tsgo.git
synced 2026-10-30 19:37:15 +00:00
25 lines
872 B
Plaintext
25 lines
872 B
Plaintext
assignmentCompatWithObjectMembers5.ts(13,1): error TS2741: Property 'foo' is missing in type 'I' but required in type 'C'.
|
|
assignmentCompatWithObjectMembers5.ts(14,1): error TS2741: Property 'fooo' is missing in type 'C' but required in type 'I'.
|
|
|
|
|
|
==== assignmentCompatWithObjectMembers5.ts (2 errors) ====
|
|
class C {
|
|
foo: string;
|
|
}
|
|
|
|
declare var c: C;
|
|
|
|
interface I {
|
|
fooo: string;
|
|
}
|
|
|
|
declare var i: I;
|
|
|
|
c = i; // error
|
|
~
|
|
!!! error TS2741: Property 'foo' is missing in type 'I' but required in type 'C'.
|
|
!!! related TS2728 assignmentCompatWithObjectMembers5.ts:2:5: 'foo' is declared here.
|
|
i = c; // error
|
|
~
|
|
!!! error TS2741: Property 'fooo' is missing in type 'C' but required in type 'I'.
|
|
!!! related TS2728 assignmentCompatWithObjectMembers5.ts:8:5: 'fooo' is declared here. |