From bce8b0b69f3ca82280f00f646994d2474ccb1b8f Mon Sep 17 00:00:00 2001 From: Joyee Cheung Date: Tue, 12 Sep 2023 12:04:27 +0200 Subject: [PATCH] deps: V8: cherry-pick b60a03df4ceb Original commit message: [api] mark v8::Script and v8::UnboundScript as v8::Data v8::UnboundModuleScript and v8::Module are already v8::Data. Mark v8::Script and v8::UnboundScript as v8::Data so that they can be used in other V8 APIs that takes v8::Data. Refs: https://github.com/nodejs/node/pull/48510 Bug: v8:14120 Change-Id: I2dd5648528c1b0030292872441758d4fb2cfcc1c Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4827307 Reviewed-by: Camillo Bruni Commit-Queue: Joyee Cheung Cr-Commit-Position: refs/heads/main@{#89727} Refs: https://github.com/v8/v8/commit/b60a03df4cebafb4c92ee644d11617ad73889e5e PR-URL: https://github.com/nodejs/node/pull/49491 Reviewed-By: Yagiz Nizipli Reviewed-By: Nitzan Uziely --- common.gypi | 2 +- deps/v8/include/v8-script.h | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/common.gypi b/common.gypi index d783c7f970237a..519ddcd28e6524 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.16', + 'v8_embedder_string': '-node.17', ##### V8 defaults for Node.js ##### diff --git a/deps/v8/include/v8-script.h b/deps/v8/include/v8-script.h index 4a8ccab7e28d1d..9b278da6d587a4 100644 --- a/deps/v8/include/v8-script.h +++ b/deps/v8/include/v8-script.h @@ -55,7 +55,7 @@ class V8_EXPORT ScriptOrModule { /** * A compiled JavaScript script, not yet tied to a Context. */ -class V8_EXPORT UnboundScript { +class V8_EXPORT UnboundScript : public Data { public: /** * Binds the script to the currently entered context. @@ -320,7 +320,7 @@ class V8_EXPORT Module : public Data { * A compiled JavaScript script, tied to a Context which was active when the * script was compiled. */ -class V8_EXPORT Script { +class V8_EXPORT Script : public Data { public: /** * A shorthand for ScriptCompiler::Compile().