Merge pull request #1400 from monsanto/flow-object-commas

Support commas as object property separators in flow
This commit is contained in:
Sebastian McKenzie 2015-05-01 09:24:08 +01:00
commit 4f255d103a

View File

@ -322,7 +322,7 @@ pp.flow_parseObjectType = function (allowStatic) {
}
pp.flow_objectTypeSemicolon = function () {
if (!this.eat(tt.semi) && this.type !== tt.braceR) {
if (!this.eat(tt.semi) && !this.eat(tt.comma) && this.type !== tt.braceR) {
this.unexpected()
}
}