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

Side by Side Diff: src/parsing/parser.h

Issue 1678303002: [es7] implement exponentiation operator proposal (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 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 unified diff | Download patch
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_PARSING_PARSER_H_ 5 #ifndef V8_PARSING_PARSER_H_
6 #define V8_PARSING_PARSER_H_ 6 #define V8_PARSING_PARSER_H_
7 7
8 #include "src/allocation.h" 8 #include "src/allocation.h"
9 #include "src/ast/ast.h" 9 #include "src/ast/ast.h"
10 #include "src/ast/scopes.h" 10 #include "src/ast/scopes.h"
(...skipping 618 matching lines...) Expand 10 before | Expand all | Expand 10 after
629 V8_INLINE Expression* SpreadCall(Expression* function, 629 V8_INLINE Expression* SpreadCall(Expression* function,
630 ZoneList<v8::internal::Expression*>* args, 630 ZoneList<v8::internal::Expression*>* args,
631 int pos); 631 int pos);
632 V8_INLINE Expression* SpreadCallNew(Expression* function, 632 V8_INLINE Expression* SpreadCallNew(Expression* function,
633 ZoneList<v8::internal::Expression*>* args, 633 ZoneList<v8::internal::Expression*>* args,
634 int pos); 634 int pos);
635 635
636 // Rewrite all DestructuringAssignments in the current FunctionState. 636 // Rewrite all DestructuringAssignments in the current FunctionState.
637 V8_INLINE void RewriteDestructuringAssignments(); 637 V8_INLINE void RewriteDestructuringAssignments();
638 638
639 V8_INLINE Expression* RewriteExponentiation(Expression* left,
640 Expression* right, int pos);
641 V8_INLINE Expression* RewriteAssignExponentiation(Expression* left,
642 Expression* right, int pos);
643
639 V8_INLINE void QueueDestructuringAssignmentForRewriting( 644 V8_INLINE void QueueDestructuringAssignmentForRewriting(
640 Expression* assignment); 645 Expression* assignment);
641 V8_INLINE void QueueNonPatternForRewriting(Expression* expr); 646 V8_INLINE void QueueNonPatternForRewriting(Expression* expr);
642 647
643 void SetFunctionNameFromPropertyName(ObjectLiteralProperty* property, 648 void SetFunctionNameFromPropertyName(ObjectLiteralProperty* property,
644 const AstRawString* name); 649 const AstRawString* name);
645 650
646 void SetFunctionNameFromIdentifierRef(Expression* value, 651 void SetFunctionNameFromIdentifierRef(Expression* value,
647 Expression* identifier); 652 Expression* identifier);
648 653
(...skipping 387 matching lines...) Expand 10 before | Expand all | Expand 10 after
1036 Expression* SpreadCall(Expression* function, 1041 Expression* SpreadCall(Expression* function,
1037 ZoneList<v8::internal::Expression*>* args, int pos); 1042 ZoneList<v8::internal::Expression*>* args, int pos);
1038 Expression* SpreadCallNew(Expression* function, 1043 Expression* SpreadCallNew(Expression* function,
1039 ZoneList<v8::internal::Expression*>* args, int pos); 1044 ZoneList<v8::internal::Expression*>* args, int pos);
1040 1045
1041 void SetLanguageMode(Scope* scope, LanguageMode mode); 1046 void SetLanguageMode(Scope* scope, LanguageMode mode);
1042 void RaiseLanguageMode(LanguageMode mode); 1047 void RaiseLanguageMode(LanguageMode mode);
1043 1048
1044 V8_INLINE void RewriteDestructuringAssignments(); 1049 V8_INLINE void RewriteDestructuringAssignments();
1045 1050
1051 V8_INLINE Expression* RewriteExponentiation(Expression* left,
1052 Expression* right, int pos);
1053 V8_INLINE Expression* RewriteAssignExponentiation(Expression* left,
1054 Expression* right, int pos);
1055
1046 friend class NonPatternRewriter; 1056 friend class NonPatternRewriter;
1047 V8_INLINE Expression* RewriteSpreads(ArrayLiteral* lit); 1057 V8_INLINE Expression* RewriteSpreads(ArrayLiteral* lit);
1048 1058
1049 V8_INLINE void RewriteNonPattern(ExpressionClassifier* classifier, bool* ok); 1059 V8_INLINE void RewriteNonPattern(ExpressionClassifier* classifier, bool* ok);
1050 1060
1051 friend class InitializerRewriter; 1061 friend class InitializerRewriter;
1052 void RewriteParameterInitializer(Expression* expr, Scope* scope); 1062 void RewriteParameterInitializer(Expression* expr, Scope* scope);
1053 1063
1054 Scanner scanner_; 1064 Scanner scanner_;
1055 PreParser* reusable_preparser_; 1065 PreParser* reusable_preparser_;
(...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after
1237 1247
1238 DoExpression* ParserTraits::ParseDoExpression(bool* ok) { 1248 DoExpression* ParserTraits::ParseDoExpression(bool* ok) {
1239 return parser_->ParseDoExpression(ok); 1249 return parser_->ParseDoExpression(ok);
1240 } 1250 }
1241 1251
1242 1252
1243 } // namespace internal 1253 } // namespace internal
1244 } // namespace v8 1254 } // namespace v8
1245 1255
1246 #endif // V8_PARSING_PARSER_H_ 1256 #endif // V8_PARSING_PARSER_H_
OLDNEW
« no previous file with comments | « src/js/math.js ('k') | src/parsing/parser.cc » ('j') | src/parsing/parser-base.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698