class A {
#a = 1;
static #a = 2;
}
Results in
Uncaught SyntaxError: redeclaration of private name #ain FirefoxUncaught SyntaxError: Identifier '#a' has already been declaredin Chrome
While
class A {
a = 1;
static a = 2;
}
is valid in both Firefox and Chrome
AFAIK instance fields will be installed on the class instance while static fields will be installed on the class object itself. They are not conflicted. Why the former code is invalid?