diff options
author | Michaël Zasso <targos@protonmail.com> | 2019-08-01 08:38:30 +0200 |
---|---|---|
committer | Michaël Zasso <targos@protonmail.com> | 2019-08-01 12:53:56 +0200 |
commit | 2dcc3665abf57c3607cebffdeeca062f5894885d (patch) | |
tree | 4f560748132edcfb4c22d6f967a7e80d23d7ea2c /deps/v8/src/ast/ast-function-literal-id-reindexer.h | |
parent | 1ee47d550c6de132f06110aa13eceb7551d643b3 (diff) | |
download | node-new-2dcc3665abf57c3607cebffdeeca062f5894885d.tar.gz |
deps: update V8 to 7.6.303.28
PR-URL: https://github.com/nodejs/node/pull/28016
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Refael Ackermann (רפאל פלחי) <refack@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
Diffstat (limited to 'deps/v8/src/ast/ast-function-literal-id-reindexer.h')
-rw-r--r-- | deps/v8/src/ast/ast-function-literal-id-reindexer.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/deps/v8/src/ast/ast-function-literal-id-reindexer.h b/deps/v8/src/ast/ast-function-literal-id-reindexer.h index 400196da68..f4dac7b01e 100644 --- a/deps/v8/src/ast/ast-function-literal-id-reindexer.h +++ b/deps/v8/src/ast/ast-function-literal-id-reindexer.h @@ -8,6 +8,10 @@ #include "src/ast/ast-traversal-visitor.h" #include "src/base/macros.h" +#ifdef DEBUG +#include <set> +#endif + namespace v8 { namespace internal { @@ -23,10 +27,22 @@ class AstFunctionLiteralIdReindexer final // AstTraversalVisitor implementation. void VisitFunctionLiteral(FunctionLiteral* lit); + void VisitClassLiteral(ClassLiteral* lit); private: int delta_; +#ifdef DEBUG + // Visited set, only used in DCHECKs for verification. + std::set<FunctionLiteral*> visited_; + + // Visit all function literals, checking if they have already been visited + // (are in the visited set). + void CheckVisited(Expression* expr); +#else + void CheckVisited(Expression* expr) {} +#endif + DISALLOW_COPY_AND_ASSIGN(AstFunctionLiteralIdReindexer); }; |