| Index: src/parsing/parser.h
|
| diff --git a/src/parsing/parser.h b/src/parsing/parser.h
|
| index 6523ca7de583e4e8ae5373b4960aa85c94238d3f..f3a086d0c25b4a55464233d72eb69ffd933dc4b8 100644
|
| --- a/src/parsing/parser.h
|
| +++ b/src/parsing/parser.h
|
| @@ -1110,6 +1110,12 @@ class V8_EXPORT_PRIVATE Parser : public NON_EXPORTED_BASE(ParserBase<Parser>) {
|
| ++use_counts_[feature];
|
| }
|
|
|
| + // Returns true iff we're parsing the first function literal during
|
| + // CreateDynamicFunction().
|
| + V8_INLINE bool ParsingDynamicFunctionDeclaration() const {
|
| + return parameters_end_pos_ != kNoSourcePosition;
|
| + }
|
| +
|
| // Parser's private field members.
|
| friend class DiscardableZoneScope; // Uses reusable_preparser_.
|
| // FIXME(marja): Make reusable_preparser_ always use its own temp Zone (call
|
| @@ -1138,6 +1144,12 @@ class V8_EXPORT_PRIVATE Parser : public NON_EXPORTED_BASE(ParserBase<Parser>) {
|
| ParserLogger* log_;
|
|
|
| PreParsedScopeData* preparsed_scope_data_;
|
| +
|
| + // If not kNoSourcePosition, indicates that the first function literal
|
| + // encountered is a dynamic function, see CreateDynamicFunction(). This field
|
| + // indicates the correct position of the ')' that closes the parameter list.
|
| + // After that ')' is encountered, this field is reset to kNoSourcePosition.
|
| + int parameters_end_pos_;
|
| };
|
|
|
| // ----------------------------------------------------------------------------
|
|
|