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

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

Issue 2156303002: Implement new Function.prototype.toString and fix CreateDynamicFunction parsing (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: fix async function constructor Created 4 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 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_PREPARSER_H 5 #ifndef V8_PARSING_PREPARSER_H
6 #define V8_PARSING_PREPARSER_H 6 #define V8_PARSING_PREPARSER_H
7 7
8 #include "src/ast/scopes.h" 8 #include "src/ast/scopes.h"
9 #include "src/parsing/parser-base.h" 9 #include "src/parsing/parser-base.h"
10 10
(...skipping 1475 matching lines...) Expand 10 before | Expand all | Expand 10 after
1486 } 1486 }
1487 1487
1488 V8_INLINE ZoneList<PreParserExpression>* GetNonPatternList() const { 1488 V8_INLINE ZoneList<PreParserExpression>* GetNonPatternList() const {
1489 return function_state_->non_patterns_to_rewrite(); 1489 return function_state_->non_patterns_to_rewrite();
1490 } 1490 }
1491 1491
1492 V8_INLINE void CountUsage(v8::Isolate::UseCounterFeature feature) { 1492 V8_INLINE void CountUsage(v8::Isolate::UseCounterFeature feature) {
1493 if (use_counts_ != nullptr) ++use_counts_[feature]; 1493 if (use_counts_ != nullptr) ++use_counts_[feature];
1494 } 1494 }
1495 1495
1496 V8_INLINE bool IgnoreFunctionName() const { return false; }
1497
1496 // Preparser's private field members. 1498 // Preparser's private field members.
1497 1499
1498 int* use_counts_; 1500 int* use_counts_;
1499 bool track_unresolved_variables_; 1501 bool track_unresolved_variables_;
1500 }; 1502 };
1501 1503
1502 PreParserExpression PreParser::SpreadCall(PreParserExpression function, 1504 PreParserExpression PreParser::SpreadCall(PreParserExpression function,
1503 PreParserExpressionList args, 1505 PreParserExpressionList args,
1504 int pos) { 1506 int pos) {
1505 return factory()->NewCall(function, args, pos); 1507 return factory()->NewCall(function, args, pos);
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
1540 function_state_->NextMaterializedLiteralIndex(); 1542 function_state_->NextMaterializedLiteralIndex();
1541 function_state_->NextMaterializedLiteralIndex(); 1543 function_state_->NextMaterializedLiteralIndex();
1542 } 1544 }
1543 return EmptyExpression(); 1545 return EmptyExpression();
1544 } 1546 }
1545 1547
1546 } // namespace internal 1548 } // namespace internal
1547 } // namespace v8 1549 } // namespace v8
1548 1550
1549 #endif // V8_PARSING_PREPARSER_H 1551 #endif // V8_PARSING_PREPARSER_H
OLDNEW
« src/objects.cc ('K') | « src/parsing/parser-base.h ('k') | src/runtime/runtime-compiler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698