From 6bce6f69c6ddda4c795a7f1140c8746872938bfa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C3=ABl=20Zasso?= Date: Sun, 1 Sep 2024 10:00:30 +0200 Subject: [PATCH] Revert "deps: remove bogus V8 DCHECK" This reverts commit fba06eb34a23188329211a1eb540ac91865b4748. PR-URL: https://github.com/nodejs/node/pull/54682 Refs: https://github.com/v8/v8/compare/12.8.374.22...12.8.374.31 Reviewed-By: Antoine du Hamel Reviewed-By: Rafael Gonzaga Reviewed-By: Jiawen Geng Reviewed-By: James M Snell --- common.gypi | 2 +- deps/v8/src/ast/scopes.cc | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/common.gypi b/common.gypi index d4c6fb9a8033cb..b2a4cd9d69c95e 100644 --- a/common.gypi +++ b/common.gypi @@ -36,7 +36,7 @@ # Reset this number to 0 on major V8 upgrades. # Increment by one for each non-official patch applied to deps/v8. - 'v8_embedder_string': '-node.14', + 'v8_embedder_string': '-node.15', ##### V8 defaults for Node.js ##### diff --git a/deps/v8/src/ast/scopes.cc b/deps/v8/src/ast/scopes.cc index d6f168e7258c48..e2b2405aaae8fb 100644 --- a/deps/v8/src/ast/scopes.cc +++ b/deps/v8/src/ast/scopes.cc @@ -2713,6 +2713,7 @@ void Scope::AllocateScopeInfosRecursively( // Allocate ScopeInfos for inner scopes. for (Scope* scope = inner_scope_; scope != nullptr; scope = scope->sibling_) { + DCHECK_GT(scope->UniqueIdInScript(), UniqueIdInScript()); DCHECK_IMPLIES(scope->sibling_, scope->sibling_->UniqueIdInScript() != scope->UniqueIdInScript()); if (!scope->is_function_scope() ||