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

Unified Diff: src/parsing/parser.cc

Issue 2279773002: [parser] Clean up type definitions (Closed)
Patch Set: Created 4 years, 4 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
« no previous file with comments | « src/parsing/parser.h ('k') | src/parsing/parser-base.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/parsing/parser.cc
diff --git a/src/parsing/parser.cc b/src/parsing/parser.cc
index 6491a17b90f4450a74f62bd3e944b00de4996ec4..51dc45567d9235530379fac34749ce5a5ab4a603 100644
--- a/src/parsing/parser.cc
+++ b/src/parsing/parser.cc
@@ -3865,7 +3865,7 @@ void Parser::ParseArrowFunctionFormalParameterList(
return;
}
- Type::ExpressionClassifier classifier(this);
+ ExpressionClassifier classifier(this);
if (!parameters->is_simple) {
classifier.RecordNonSimpleParameter();
}
@@ -5259,11 +5259,9 @@ uint32_t Parser::ComputeTemplateLiteralHash(const TemplateLiteral* lit) {
return running_hash;
}
-
-ZoneList<v8::internal::Expression*>* Parser::PrepareSpreadArguments(
- ZoneList<v8::internal::Expression*>* list) {
- ZoneList<v8::internal::Expression*>* args =
- new (zone()) ZoneList<v8::internal::Expression*>(1, zone());
+ZoneList<Expression*>* Parser::PrepareSpreadArguments(
+ ZoneList<Expression*>* list) {
+ ZoneList<Expression*>* args = new (zone()) ZoneList<Expression*>(1, zone());
if (list->length() == 1) {
// Spread-call with single spread argument produces an InternalArray
// containing the values from the array.
@@ -5290,8 +5288,8 @@ ZoneList<v8::internal::Expression*>* Parser::PrepareSpreadArguments(
int n = list->length();
while (i < n) {
if (!list->at(i)->IsSpread()) {
- ZoneList<v8::internal::Expression*>* unspread =
- new (zone()) ZoneList<v8::internal::Expression*>(1, zone());
+ ZoneList<Expression*>* unspread =
+ new (zone()) ZoneList<Expression*>(1, zone());
// Push array of unspread parameters
while (i < n && !list->at(i)->IsSpread()) {
@@ -5306,15 +5304,15 @@ ZoneList<v8::internal::Expression*>* Parser::PrepareSpreadArguments(
}
// Push eagerly spread argument
- ZoneList<v8::internal::Expression*>* spread_list =
- new (zone()) ZoneList<v8::internal::Expression*>(1, zone());
+ ZoneList<Expression*>* spread_list =
+ new (zone()) ZoneList<Expression*>(1, zone());
spread_list->Add(list->at(i++)->AsSpread()->expression(), zone());
args->Add(factory()->NewCallRuntime(Context::SPREAD_ITERABLE_INDEX,
spread_list, kNoSourcePosition),
zone());
}
- list = new (zone()) ZoneList<v8::internal::Expression*>(1, zone());
+ list = new (zone()) ZoneList<Expression*>(1, zone());
list->Add(factory()->NewCallRuntime(Context::SPREAD_ARGUMENTS_INDEX, args,
kNoSourcePosition),
zone());
@@ -5323,10 +5321,8 @@ ZoneList<v8::internal::Expression*>* Parser::PrepareSpreadArguments(
UNREACHABLE();
}
-
Expression* Parser::SpreadCall(Expression* function,
- ZoneList<v8::internal::Expression*>* args,
- int pos) {
+ ZoneList<Expression*>* args, int pos) {
if (function->IsSuperCallReference()) {
// Super calls
// $super_constructor = %_GetSuperConstructor(<this-function>)
@@ -5368,10 +5364,8 @@ Expression* Parser::SpreadCall(Expression* function,
}
}
-
Expression* Parser::SpreadCallNew(Expression* function,
- ZoneList<v8::internal::Expression*>* args,
- int pos) {
+ ZoneList<Expression*>* args, int pos) {
args->InsertAt(0, function, zone());
return factory()->NewCallRuntime(Context::REFLECT_CONSTRUCT_INDEX, args, pos);
« no previous file with comments | « src/parsing/parser.h ('k') | src/parsing/parser-base.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698