0
0
Fork 0
mirror of https://github.com/denoland/rusty_v8.git synced 2024-11-24 15:19:31 -05:00
This commit is contained in:
Bartek Iwańczuk 2022-05-25 17:53:49 +02:00 committed by Bert Belder
parent 6f671c05d0
commit 25b6329bf5
No known key found for this signature in database
GPG key ID: 7A77887B2E2ED461
2 changed files with 6 additions and 2 deletions

View file

@ -116,7 +116,10 @@ impl SnapshotCreator {
/// Create and enter an isolate, and set it up for serialization.
/// The isolate is created from scratch.
#[inline(always)]
pub fn new(external_references: Option<&'static ExternalReferences>, existing_blob: Option<&StartupData>) -> Self {
pub fn new(
external_references: Option<&'static ExternalReferences>,
existing_blob: Option<&StartupData>,
) -> Self {
let mut snapshot_creator: MaybeUninit<Self> = MaybeUninit::uninit();
let external_references_ptr = if let Some(er) = external_references {
er.as_ptr()

View file

@ -3500,7 +3500,8 @@ fn snapshot_creator() {
};
let startup_data = {
let mut snapshot_creator = v8::SnapshotCreator::new(None, Some(&startup_data));
let mut snapshot_creator =
v8::SnapshotCreator::new(None, Some(&startup_data));
// TODO(ry) this shouldn't be necessary. workaround unfinished business in
// the scope type system.
let mut isolate = unsafe { snapshot_creator.get_owned_isolate() };