Skip to content
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

core: introduce serde_v8 #9722

Merged
merged 24 commits into from
Mar 26, 2021
Merged
Changes from 1 commit
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
tweaks
  • Loading branch information
AaronO committed Mar 19, 2021
commit 9953b72586e7aa2b49bc62eaa06e3a3b61325c20
7 changes: 3 additions & 4 deletions core/bindings.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ use std::option::Option;
use url::Url;
use v8::MapFnTo;

use serde::{Serialize};
use serde_v8::{from_v8, to_v8};
use serde::Serialize;
use serde_v8::to_v8;

lazy_static! {
pub static ref EXTERNAL_REFERENCES: v8::ExternalReferences =
Expand Down Expand Up @@ -482,7 +482,7 @@ fn eval_context(
thrown: serde_v8::Value<'s>,
is_native_error: bool,
is_compile_error: bool,
};
}

let tc_scope = &mut v8::TryCatch::new(scope);
let name = v8::String::new(
Expand Down Expand Up @@ -781,7 +781,6 @@ fn get_promise_details(
args: v8::FunctionCallbackArguments,
mut rv: v8::ReturnValue,
) {

let promise = match v8::Local::<v8::Promise>::try_from(args.get(0)) {
Ok(val) => val,
Err(_) => {
Expand Down