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

Unified Diff: src/parser.h

Issue 938443002: [es6] implement spread calls (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Add more variations to evaluation order tests Created 5 years, 10 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/parser.h
diff --git a/src/parser.h b/src/parser.h
index bc0b7ab51b0546257d807260331c540098d6d133..22c48b8d6642634495aad50dc7e2e0582dab5eda 100644
--- a/src/parser.h
+++ b/src/parser.h
@@ -627,6 +627,16 @@ class ParserTraits {
return tag != NULL;
}
+ V8_INLINE ZoneList<v8::internal::Expression*>* PrepareSpreadArguments(
+ ZoneList<v8::internal::Expression*>* list);
+ V8_INLINE void MaterializeUnspreadArgumentsLiterals(int count) {}
+ V8_INLINE Expression* SpreadCall(Expression* function,
+ ZoneList<v8::internal::Expression*>* args,
+ int pos);
+ V8_INLINE Expression* SpreadCallNew(Expression* function,
+ ZoneList<v8::internal::Expression*>* args,
+ int pos);
+
private:
Parser* parser_;
};
@@ -834,6 +844,13 @@ class Parser : public ParserBase<ParserTraits> {
Expression* tag);
uint32_t ComputeTemplateLiteralHash(const TemplateLiteral* lit);
+ ZoneList<v8::internal::Expression*>* PrepareSpreadArguments(
+ ZoneList<v8::internal::Expression*>* list);
+ Expression* SpreadCall(Expression* function,
+ ZoneList<v8::internal::Expression*>* args, int pos);
+ Expression* SpreadCallNew(Expression* function,
+ ZoneList<v8::internal::Expression*>* args, int pos);
+
Scanner scanner_;
PreParser* reusable_preparser_;
Scope* original_scope_; // for ES5 function declarations in sloppy eval
@@ -949,6 +966,25 @@ Expression* ParserTraits::CloseTemplateLiteral(TemplateLiteralState* state,
int start, Expression* tag) {
return parser_->CloseTemplateLiteral(state, start, tag);
}
+
+
+ZoneList<v8::internal::Expression*>* ParserTraits::PrepareSpreadArguments(
+ ZoneList<v8::internal::Expression*>* list) {
+ return parser_->PrepareSpreadArguments(list);
+}
+
+
+Expression* ParserTraits::SpreadCall(Expression* function,
+ ZoneList<v8::internal::Expression*>* args,
+ int pos) {
+ return parser_->SpreadCall(function, args, pos);
+}
+
+
+Expression* ParserTraits::SpreadCallNew(
+ Expression* function, ZoneList<v8::internal::Expression*>* args, int pos) {
+ return parser_->SpreadCallNew(function, args, pos);
+}
} } // namespace v8::internal
#endif // V8_PARSER_H_

Powered by Google App Engine
This is Rietveld 408576698