MODULE@0..22
CLASS_DECL@0..19
CLASS_KW@0..5 "class"
WHITESPACE@5..6 " "
NAME@6..9
IDENT@6..9 "foo"
WHITESPACE@9..10 " "
CLASS_BODY@10..19
L_CURLY@10..11 "{"
WHITESPACE@11..13 "\n "
CLASS_PROP@13..16
NAME@13..16
IDENT@13..16 "get"
WHITESPACE@16..17 " "
ERROR@17..18
L_CURLY@17..18 "{"
R_CURLY@18..19 "}"
WHITESPACE@19..20 "\n"
ERROR@20..21
R_CURLY@20..21 "}"
WHITESPACE@21..22 "\n"
--
error[SyntaxError]: expected a semicolon for a class property, but found none
┌─ method_getter_err.js:2:2
│
2 │ get {}
│ ^^^^
--
error[SyntaxError]: class fields are unsupported
┌─ method_getter_err.js:2:2
│
2 │ get {}
│ ^^^
--
error[SyntaxError]: Expected an identifier or keyword
┌─ method_getter_err.js:2:6
│
2 │ get {}
│ ^ Expected an identifier or keyword here
--
error[SyntaxError]: expected `;`, a property, or a method for a class body, but found none
┌─ method_getter_err.js:2:6
│
2 │ get {}
│ ^
--
error[SyntaxError]: Expected a statement or declaration, but found none
┌─ method_getter_err.js:3:1
│
3 │ }
│ ^ Expected a statement or declaration here
--
class foo {
get {}
}