ratel-rust / ratel-core

High performance JavaScript to JavaScript compiler with a Rust core
Apache License 2.0
435 stars 17 forks source link

Support getter/setter syntax #145

Open Brooooooklyn opened 4 years ago

Brooooooklyn commented 4 years ago
var a = {
 _foo: 1,
 get foo () {
  return this._foo
 }
}

Error: Unexpected token at 3:6 1 | var a = { 2 | _foo: 1,> 3 | get foo () { | ^^^ 4 | return this._foo 5 | }Unexpected token at 3:11 1 | var a = { 2 | _foo: 1,> 3 | get foo () { | ^ 4 | return this._foo 5 | }Unexpected token at 5:3 3 | get foo () { 4 | return this._foo> 5 | } | ^ 6 | }