Closed Bug 1679237 Opened 4 years ago Closed 4 years ago

Support private class data members

Categories

(Core :: JavaScript Engine, enhancement)

Firefox 83
enhancement

Tracking

()

RESOLVED DUPLICATE of bug 1562054

People

(Reporter: d3ck0r, Unassigned)

Details

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.66 Safari/537.36

Steps to reproduce:

JS code

class World {
    #sector = null;
    get sector() { return this.#sector };
}

Actual results:

Firefox throws the exception

'Uncaught SyntaxError: private fields are not currently supported'

Expected results:

Private data fields should currently be supported.
Where can I find an issue to track this progress so I can know when I can use firefox?

I was just putting together this toy project, and found class private data members worked, which simplifies issues with JSON.stringify( classInstance ) where I don't send things that aren't visible.

Bugbug thinks this bug should belong to this component, but please revert this change in case of error.

Component: Untriaged → JavaScript Engine
Product: Firefox → Core
Status: UNCONFIRMED → RESOLVED
Closed: 4 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.