class Test {
#x = 'private'
}const test = new Test()
console.log(test.#x)SyntaxError: Private field '#x' must be declared in an enclosing class
SyntaxError: Attempting to access private field '#x"
--
--
v8-dev mailing list
v8-...@googlegroups.com
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to v8-dev+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/v8-dev/f0837372-d8ea-4444-84fc-a6c9d0866656%40googlegroups.com.
On Thu, Jan 16, 2020 at 4:33 AM <chenh...@gmail.com> wrote:
First I created a test class like this below:--class Test {
#x = 'private'
}And then when I attempted to get that private field "#x":const test = new Test()
console.log(test.#x)
I recieved an error like this:SyntaxError: Private field '#x' must be declared in an enclosing classI thought that this error message is confusing. A better one could be like this:SyntaxError: Attempting to access private field '#x"
--
v8-dev mailing list
v8-...@googlegroups.com
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to v8-...@googlegroups.com.
You received this message because you are subscribed to a topic in the Google Groups "v8-dev" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/v8-dev/vDlefmP-Kko/unsubscribe.
To unsubscribe from this group and all its topics, send an email to v8-dev+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/v8-dev/8ffaf5c3-c56b-4727-ae74-4ec1540494c2%40googlegroups.com.