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

Unified Diff: src/preparser.cc

Issue 196343033: Make PreParser track valid left hand sides. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 9 months 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
Index: src/preparser.cc
diff --git a/src/preparser.cc b/src/preparser.cc
index 398f32744cb61ff6c5e5af317d22b8d117f37b9f..e9f29b3dba275394401158a01654e4e68667549e 100644
--- a/src/preparser.cc
+++ b/src/preparser.cc
@@ -874,7 +874,7 @@ PreParser::Expression PreParser::ParseLeftHandSideExpression(bool* ok) {
if (result.IsThis()) {
result = Expression::ThisProperty();
} else {
- result = Expression::Default();
+ result = Expression::Property();
}
break;
}
@@ -891,7 +891,7 @@ PreParser::Expression PreParser::ParseLeftHandSideExpression(bool* ok) {
if (result.IsThis()) {
result = Expression::ThisProperty();
} else {
- result = Expression::Default();
+ result = Expression::Property();
}
break;
}
@@ -980,7 +980,7 @@ PreParser::Expression PreParser::ParseMemberExpressionContinuation(
if (expression.IsThis()) {
expression = Expression::ThisProperty();
} else {
- expression = Expression::Default();
+ expression = Expression::Property();
}
break;
}
@@ -990,7 +990,7 @@ PreParser::Expression PreParser::ParseMemberExpressionContinuation(
if (expression.IsThis()) {
expression = Expression::ThisProperty();
} else {
- expression = Expression::Default();
+ expression = Expression::Property();
}
break;
}
@@ -1102,7 +1102,6 @@ PreParser::Expression PreParser::ParseFunctionLiteral(
int end_position = scanner()->location().end_pos;
CheckOctalLiteral(start_position, end_position, CHECK_OK);
- return Expression::StrictFunction();
}
return Expression::Default();
« no previous file with comments | « src/preparser.h ('k') | test/cctest/test-parsing.cc » ('j') | test/cctest/test-parsing.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698