-
Notifications
You must be signed in to change notification settings - Fork 31.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
src: initialize privateSymbols for per_context #57479
Conversation
Review requested:
|
4044d5d
to
4c9445f
Compare
4c9445f
to
f4643b9
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #57479 +/- ##
=======================================
Coverage 90.23% 90.23%
=======================================
Files 630 630
Lines 185129 185077 -52
Branches 36234 36222 -12
=======================================
- Hits 167049 167008 -41
- Misses 11037 11039 +2
+ Partials 7043 7030 -13
🚀 New features to boost your workflow:
|
f4643b9
to
0b6c017
Compare
0b6c017
to
22cdade
Compare
22cdade
to
e518bf4
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM % a small nit
Failed to start CI⚠ Commits were pushed since the last approving review: ⚠ - src: initialize privateSymbols for per_context ⚠ - fix: MessagePort::MoveToContext crash ⚠ - fix: check isolate_data when InitializePrivateSymbols ⚠ - maybe local for initialize ✘ Refusing to run CI on potentially unsafe PRhttps://github.com/nodejs/node/actions/runs/14195293697 |
// To initialize the per-context binding exports, a non-nullptr isolate_data | ||
// is needed | ||
CHECK(isolate_data); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need this CHECK
given that we have it also in InitializePrivateSymbols
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think they guard in different levels. InitializePrivateSymbols
checks that it must be invoked with a non-null isolate_data
. Here, it checks that if GetPerContextExports
is invoked the "first time" (like in node_mksnapshot
), the isolate_data
must not be null.
Landed in 79eddc6 |
In some cases,
per_context
files need to access privateSymbols. This commit letsGetPerContextExports
to be able to pass downIsolateData
toInitializePrimordials
, so it can compileper_context
files withprivateSymbols
fromIsolateData
.With this change we can access
privateSymbols
inper_context/domexception.js
like