Revert "babylon: fix error location for class properties with a missing semicolon"

This reverts commit f31099f383b52cf4fe1786188f6421529dea865b.
This commit is contained in:
Logan Smyth 2016-02-06 18:36:22 -08:00
parent 024cba6433
commit d9ade8a63a
3 changed files with 3 additions and 3 deletions

View File

@ -748,7 +748,7 @@ pp.parseClassProperty = function (node) {
node.value = null;
}
if (!this.eat(tt.semi)) {
this.raise(node.value && node.value.end || node.key.end, "A semicolon is required after a class property");
this.raise(this.state.start, "A semicolon is required after a class property");
}
return this.finishNode(node, "ClassProperty");
};

View File

@ -1,4 +1,4 @@
{
"throws": "A semicolon is required after a class property (2:10)",
"throws": "A semicolon is required after a class property (3:0)",
"plugins": ["classProperties"]
}

View File

@ -1,4 +1,4 @@
{
"throws": "A semicolon is required after a class property (2:6)",
"throws": "A semicolon is required after a class property (3:0)",
"plugins": ["classProperties"]
}