diff options
-rw-r--r-- | Cargo.lock | 4 | ||||
-rw-r--r-- | core/Cargo.toml | 2 | ||||
-rw-r--r-- | core/bindings.rs | 12 | ||||
-rw-r--r-- | core/icudtl.dat | bin | 10144432 -> 10284336 bytes | |||
-rw-r--r-- | core/runtime.rs | 4 | ||||
-rw-r--r-- | core/serialize_deserialize_test.js | 6 | ||||
-rw-r--r-- | serde_v8/Cargo.toml | 2 | ||||
-rw-r--r-- | serde_v8/examples/basic.rs | 2 | ||||
-rw-r--r-- | serde_v8/src/utils.rs | 2 |
9 files changed, 14 insertions, 20 deletions
diff --git a/Cargo.lock b/Cargo.lock index fb6f4d688..de050f98c 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -4836,9 +4836,9 @@ dependencies = [ [[package]] name = "v8" -version = "0.40.2" +version = "0.41.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "739aa8ce7593f9298bc5a0eb676ba6cb4e48fa0ed51c1aaa2560df7c46c0259b" +checksum = "a9c3d267007e1f137d79b4da64267139a86034a4d85df4964334979c1c7a708a" dependencies = [ "bitflags", "fslock", diff --git a/core/Cargo.toml b/core/Cargo.toml index 2ae70621c..db18b025e 100644 --- a/core/Cargo.toml +++ b/core/Cargo.toml @@ -25,7 +25,7 @@ serde = { version = "1.0.129", features = ["derive"] } serde_json = { version = "1.0.66", features = ["preserve_order"] } serde_v8 = { version = "0.33.0", path = "../serde_v8" } url = { version = "2.2.2", features = ["serde"] } -v8 = "0.40.2" +v8 = "0.41.0" [[example]] name = "http_bench_json_ops" diff --git a/core/bindings.rs b/core/bindings.rs index 4fd2678fd..084d30a15 100644 --- a/core/bindings.rs +++ b/core/bindings.rs @@ -246,7 +246,8 @@ pub fn set_func( pub extern "C" fn host_import_module_dynamically_callback( context: v8::Local<v8::Context>, - referrer: v8::Local<v8::ScriptOrModule>, + _host_defined_options: v8::Local<v8::Data>, + resource_name: v8::Local<v8::Value>, specifier: v8::Local<v8::String>, import_assertions: v8::Local<v8::FixedArray>, ) -> *mut v8::Promise { @@ -257,18 +258,11 @@ pub extern "C" fn host_import_module_dynamically_callback( .to_string(scope) .unwrap() .to_rust_string_lossy(scope); - let referrer_name = referrer.get_resource_name(); - let referrer_name_str = referrer_name + let referrer_name_str = resource_name .to_string(scope) .unwrap() .to_rust_string_lossy(scope); - // TODO(ry) I'm not sure what HostDefinedOptions is for or if we're ever going - // to use it. For now we check that it is not used. This check may need to be - // changed in the future. - let host_defined_options = referrer.get_host_defined_options(); - assert_eq!(host_defined_options.length(), 0); - let resolver = v8::PromiseResolver::new(scope).unwrap(); let promise = resolver.get_promise(scope); diff --git a/core/icudtl.dat b/core/icudtl.dat Binary files differindex e511b9a8c..0e35d1dab 100644 --- a/core/icudtl.dat +++ b/core/icudtl.dat diff --git a/core/runtime.rs b/core/runtime.rs index 42b66e13f..7555bc301 100644 --- a/core/runtime.rs +++ b/core/runtime.rs @@ -196,9 +196,9 @@ impl Drop for JsRuntime { fn v8_init(v8_platform: Option<v8::SharedRef<v8::Platform>>) { // Include 10MB ICU data file. #[repr(C, align(16))] - struct IcuData([u8; 10144432]); + struct IcuData([u8; 10284336]); static ICU_DATA: IcuData = IcuData(*include_bytes!("icudtl.dat")); - v8::icu::set_common_data_69(&ICU_DATA.0).unwrap(); + v8::icu::set_common_data_70(&ICU_DATA.0).unwrap(); let v8_platform = v8_platform .unwrap_or_else(|| v8::new_default_platform(0, false).make_shared()); diff --git a/core/serialize_deserialize_test.js b/core/serialize_deserialize_test.js index 86ef0eaac..f15fc04e8 100644 --- a/core/serialize_deserialize_test.js +++ b/core/serialize_deserialize_test.js @@ -19,7 +19,7 @@ function assertArrayEquals(a1, a2) { function main() { const emptyString = ""; - const emptyStringSerialized = [255, 14, 34, 0]; + const emptyStringSerialized = [255, 15, 34, 0]; assertArrayEquals(Deno.core.serialize(emptyString), emptyStringSerialized); assert( Deno.core.deserialize(new Uint8Array(emptyStringSerialized)) === @@ -29,7 +29,7 @@ function main() { const primitiveValueArray = ["test", "a", null, undefined]; // deno-fmt-ignore const primitiveValueArraySerialized = [ - 255, 14, 65, 4, 34, 4, 116, 101, 115, 116, + 255, 15, 65, 4, 34, 4, 116, 101, 115, 116, 34, 1, 97, 48, 95, 36, 0, 4, ]; assertArrayEquals( @@ -48,7 +48,7 @@ function main() { circularObject.test = circularObject; // deno-fmt-ignore const circularObjectSerialized = [ - 255, 14, 111, 34, 4, 116, 101, 115, + 255, 15, 111, 34, 4, 116, 101, 115, 116, 94, 0, 34, 5, 116, 101, 115, 116, 50, 34, 2, 100, 100, 34, 5, 116, 101, 115, 116, 51, 34, 2, 97, diff --git a/serde_v8/Cargo.toml b/serde_v8/Cargo.toml index 0ac6f4f0d..0c00008c9 100644 --- a/serde_v8/Cargo.toml +++ b/serde_v8/Cargo.toml @@ -12,7 +12,7 @@ description = "Rust to V8 serialization and deserialization" [dependencies] serde = { version = "1.0.130", features = ["derive"] } serde_bytes = "0.11" -v8 = "0.40.2" +v8 = "0.41.0" [dev-dependencies] bencher = "0.1" diff --git a/serde_v8/examples/basic.rs b/serde_v8/examples/basic.rs index 252e3fc06..81a8e6e6c 100644 --- a/serde_v8/examples/basic.rs +++ b/serde_v8/examples/basic.rs @@ -55,5 +55,5 @@ fn main() { unsafe { v8::V8::dispose(); } - v8::V8::shutdown_platform(); + v8::V8::dispose_platform(); } diff --git a/serde_v8/src/utils.rs b/serde_v8/src/utils.rs index 630573206..427ac5f2f 100644 --- a/serde_v8/src/utils.rs +++ b/serde_v8/src/utils.rs @@ -20,7 +20,7 @@ pub fn v8_shutdown() { unsafe { v8::V8::dispose(); } - v8::V8::shutdown_platform(); + v8::V8::dispose_platform(); } pub fn v8_do(f: impl FnOnce()) { |