Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1195)

Unified Diff: frog/frogsh

Issue 8678011: fix parser error (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: prereviewed Created 9 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | frog/parser.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: frog/frogsh
diff --git a/frog/frogsh b/frog/frogsh
index 8e24e8bd7650908fa8abbedf5b9ed5ba1d075032..c5ce1d4f97f819185529dea7ddb91cf22101e786 100755
--- a/frog/frogsh
+++ b/frog/frogsh
@@ -19168,12 +19168,16 @@ lang_Parser.prototype.finishPostfixExpression = function(expr) {
}
}
lang_Parser.prototype.finishCallOrLambdaExpression = function(expr) {
+ var $0;
if ($notnull_bool(this._atClosureParameters())) {
var formals = this.formalParameterList();
var body = this.functionBody(true);
return this._makeFunction(expr, formals, body);
}
else {
+ if ((expr instanceof DeclaredIdentifier)) {
+ this._lang_error('illegal target for call, did you mean to declare a function?', (($0 = expr.get$span()) && $0.is$SourceSpan()));
+ }
var args = this.arguments();
return this.finishPostfixExpression(new CallExpression(expr, args, this._makeSpan($assert_num(expr.get$span().get$start()))));
}
@@ -19538,7 +19542,7 @@ lang_Parser.parseHex = function(hex) {
for (var i = 0;
i < hex.length; i++) {
var digit = lang_Parser._hexDigit(hex.charCodeAt(i));
- $assert($ne(digit, -1), "digit != -1", "parser.dart", 1339, 14);
+ $assert($ne(digit, -1), "digit != -1", "parser.dart", 1343, 14);
result = (result << 4) + $assert_num(digit);
}
return $assert_num(result);
« no previous file with comments | « no previous file | frog/parser.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698