mirror of
https://github.com/hanzoai/tsgo.git
synced 2026-10-30 19:37:15 +00:00
29 lines
811 B
Plaintext
29 lines
811 B
Plaintext
autolift4.ts(19,70): error TS2339: Property 'm' does not exist on type 'Point3D'.
|
|
|
|
|
|
==== autolift4.ts (1 errors) ====
|
|
class Point {
|
|
|
|
constructor(public x: number, public y: number) {
|
|
|
|
}
|
|
getDist() {
|
|
return Math.sqrt(this.x*this.x + this.y*this.y);
|
|
}
|
|
static origin = new Point(0,0);
|
|
}
|
|
|
|
class Point3D extends Point {
|
|
|
|
constructor(x: number, y: number, public z: number, m:number) {
|
|
super(x, y);
|
|
}
|
|
|
|
getDist() {
|
|
return Math.sqrt(this.x*this.x + this.y*this.y + this.z*this.m);
|
|
~
|
|
!!! error TS2339: Property 'm' does not exist on type 'Point3D'.
|
|
}
|
|
}
|
|
|
|
|