mirror of
https://github.com/hanzoai/tsgo.git
synced 2026-10-30 19:37:15 +00:00
18 lines
910 B
Plaintext
18 lines
910 B
Plaintext
classImplementsClass7.ts(2,13): error TS2564: Property 'x' has no initializer and is not definitely assigned in the constructor.
|
|
classImplementsClass7.ts(5,7): error TS2720: Class 'B' incorrectly implements class 'A'. Did you mean to extend 'A' and inherit its members as a subclass?
|
|
Property 'x' is missing in type 'B' but required in type 'A'.
|
|
|
|
|
|
==== classImplementsClass7.ts (2 errors) ====
|
|
class A {
|
|
private x: number;
|
|
~
|
|
!!! error TS2564: Property 'x' has no initializer and is not definitely assigned in the constructor.
|
|
}
|
|
|
|
class B implements A {}
|
|
~
|
|
!!! error TS2720: Class 'B' incorrectly implements class 'A'. Did you mean to extend 'A' and inherit its members as a subclass?
|
|
!!! error TS2720: Property 'x' is missing in type 'B' but required in type 'A'.
|
|
!!! related TS2728 classImplementsClass7.ts:2:13: 'x' is declared here.
|
|
|