Allowing more flexible linebreaks/indentation within object literals.

This commit is contained in:
Jeremy Ashkenas
2010-05-12 18:28:40 -04:00
parent 9d09bee6fb
commit 7e3c71ed19
4 changed files with 137 additions and 136 deletions

View File

@@ -266,9 +266,8 @@ grammar: {
o "", -> []
o "AssignObj", -> [$1]
o "AssignList , AssignObj", -> $1.concat [$3]
o "AssignList TERMINATOR AssignObj", -> $1.concat [$3]
o "AssignList , TERMINATOR AssignObj", -> $1.concat [$4]
o "INDENT AssignList OptComma OUTDENT", -> $2
o "AssignList OptComma TERMINATOR AssignObj", -> $1.concat [$4]
o "AssignList OptComma INDENT AssignList OptComma OUTDENT", -> $1.concat $4
]
# Class definitions have optional bodies of prototype property assignments,