summaryrefslogtreecommitdiff
path: root/core
diff options
context:
space:
mode:
Diffstat (limited to 'core')
-rw-r--r--core/Cargo.toml1
-rw-r--r--core/bindings.rs2
-rw-r--r--core/lib.rs1
-rw-r--r--core/ops.rs3
-rw-r--r--core/runtime.rs2
5 files changed, 3 insertions, 6 deletions
diff --git a/core/Cargo.toml b/core/Cargo.toml
index 1e23f788e..a06e1e43f 100644
--- a/core/Cargo.toml
+++ b/core/Cargo.toml
@@ -14,7 +14,6 @@ path = "lib.rs"
[dependencies]
anyhow = "1.0.38"
-erased-serde = "0.3.13"
futures = "0.3.12"
indexmap = "1.6.1"
lazy_static = "1.4.0"
diff --git a/core/bindings.rs b/core/bindings.rs
index 3484d3cbd..f086e1f9c 100644
--- a/core/bindings.rs
+++ b/core/bindings.rs
@@ -438,7 +438,7 @@ fn send<'s>(
match op {
Op::Sync(resp) => match resp {
OpResponse::Value(v) => {
- rv.set(to_v8(scope, v).unwrap());
+ rv.set(v.to_v8(scope).unwrap());
}
OpResponse::Buffer(buf) => {
rv.set(boxed_slice_to_uint8array(scope, buf).into());
diff --git a/core/lib.rs b/core/lib.rs
index 3ee08689e..f51411083 100644
--- a/core/lib.rs
+++ b/core/lib.rs
@@ -65,7 +65,6 @@ pub use crate::ops::OpResponse;
pub use crate::ops::OpState;
pub use crate::ops::OpTable;
pub use crate::ops::PromiseId;
-pub use crate::ops::Serializable;
pub use crate::ops_bin::bin_op_async;
pub use crate::ops_bin::bin_op_sync;
pub use crate::ops_bin::ValueOrVector;
diff --git a/core/ops.rs b/core/ops.rs
index 5bd0928b6..1a2a2ebc7 100644
--- a/core/ops.rs
+++ b/core/ops.rs
@@ -22,7 +22,6 @@ use std::ops::DerefMut;
use std::pin::Pin;
use std::rc::Rc;
-pub use erased_serde::Serialize as Serializable;
pub type PromiseId = u64;
pub type OpAsyncFuture = Pin<Box<dyn Future<Output = OpResponse>>>;
pub type OpFn =
@@ -60,7 +59,7 @@ impl<'a, 'b, 'c> OpPayload<'a, 'b, 'c> {
}
pub enum OpResponse {
- Value(Box<dyn Serializable>),
+ Value(Box<dyn serde_v8::Serializable>),
Buffer(Box<[u8]>),
}
diff --git a/core/runtime.rs b/core/runtime.rs
index a64a71449..f358cf05e 100644
--- a/core/runtime.rs
+++ b/core/runtime.rs
@@ -1419,7 +1419,7 @@ impl JsRuntime {
let (promise_id, resp) = overflown_response;
args.push(v8::Integer::new(scope, promise_id as i32).into());
args.push(match resp {
- OpResponse::Value(value) => serde_v8::to_v8(scope, value).unwrap(),
+ OpResponse::Value(value) => value.to_v8(scope).unwrap(),
OpResponse::Buffer(buf) => {
bindings::boxed_slice_to_uint8array(scope, buf).into()
}