Allow arrow functions getters

It would overwrite instead of override.

class A {
  get x: () => 1
}
class B extends A {
  get x: () => super.x + 1 // undefined + 1 (B's x overwrites A's x)
}

new B().x // NaN

or in the case of being in the base class only, there would be an override but installed by the base class

class A {
  get x: () => 1
}
class B extends A {
  get x() { return 2 }
}

new B().x // 1 (A's instance version overrides version in B's prototype)
1 Like