mirror of
https://github.com/denoland/rusty_v8.git
synced 2024-12-26 09:13:46 -05:00
chore: update V8 to latest floated patch (#1354)
Co-authored-by: Divy Srivastava <dj.srivastava23@gmail.com>
This commit is contained in:
parent
ba5d0870db
commit
be0e017cd5
3 changed files with 12 additions and 19 deletions
3
.gn
3
.gn
|
@ -66,4 +66,7 @@ default_args = {
|
||||||
# https://chromium-review.googlesource.com/c/v8/v8/+/4753150, but it still
|
# https://chromium-review.googlesource.com/c/v8/v8/+/4753150, but it still
|
||||||
# fails to compile.
|
# fails to compile.
|
||||||
v8_enable_maglev = false
|
v8_enable_maglev = false
|
||||||
|
|
||||||
|
# Enable Deno-specific extra bindings
|
||||||
|
deno_enable_extras = true
|
||||||
}
|
}
|
||||||
|
|
|
@ -52,7 +52,7 @@ mod setup {
|
||||||
))
|
))
|
||||||
.is_ok());
|
.is_ok());
|
||||||
v8::V8::set_flags_from_string(
|
v8::V8::set_flags_from_string(
|
||||||
"--no_freeze_flags_after_init --expose_deno_builtins --expose_gc --harmony-import-assertions --harmony-shadow-realm --allow_natives_syntax --turbo_fast_api_calls",
|
"--no_freeze_flags_after_init --expose_gc --harmony-import-assertions --harmony-shadow-realm --allow_natives_syntax --turbo_fast_api_calls",
|
||||||
);
|
);
|
||||||
v8::V8::initialize_platform(
|
v8::V8::initialize_platform(
|
||||||
v8::new_unprotected_default_platform(0, false).make_shared(),
|
v8::new_unprotected_default_platform(0, false).make_shared(),
|
||||||
|
@ -4175,6 +4175,13 @@ fn context_get_extras_binding_object() {
|
||||||
let scope = &mut v8::ContextScope::new(scope, context);
|
let scope = &mut v8::ContextScope::new(scope, context);
|
||||||
let extras_binding = context.get_extras_binding_object(scope);
|
let extras_binding = context.get_extras_binding_object(scope);
|
||||||
assert!(extras_binding.is_object());
|
assert!(extras_binding.is_object());
|
||||||
|
|
||||||
|
// Verify that Deno specific APIs are available on the extras object.
|
||||||
|
for builtin_name in &["fromUtf8", "toUtf8", "isOneByte"] {
|
||||||
|
let name = v8::String::new(scope, builtin_name).unwrap();
|
||||||
|
let value = extras_binding.get(scope, name.into()).unwrap();
|
||||||
|
assert!(value.is_function());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -10901,20 +10908,3 @@ fn allow_scope_in_read_host_object() {
|
||||||
let value = deserializer.read_value(context).unwrap();
|
let value = deserializer.read_value(context).unwrap();
|
||||||
assert!(value.is_object());
|
assert!(value.is_object());
|
||||||
}
|
}
|
||||||
|
|
||||||
#[test]
|
|
||||||
fn has_deno_builtins() {
|
|
||||||
let _setup_guard = setup::parallel_test();
|
|
||||||
|
|
||||||
let isolate = &mut v8::Isolate::new(Default::default());
|
|
||||||
|
|
||||||
let scope = &mut v8::HandleScope::new(isolate);
|
|
||||||
let context = v8::Context::new(scope);
|
|
||||||
let scope = &mut v8::ContextScope::new(scope, context);
|
|
||||||
|
|
||||||
for builtin_name in &["fromUtf8", "toUtf8", "isOneByte"] {
|
|
||||||
let name = v8::String::new(scope, builtin_name).unwrap();
|
|
||||||
let value = context.global(scope).get(scope, name.into()).unwrap();
|
|
||||||
assert!(value.is_function());
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
2
v8
2
v8
|
@ -1 +1 @@
|
||||||
Subproject commit 99232750c02ebf21013c72ffaec0f0d7c3bfb964
|
Subproject commit 39650ed07cb96533a601a8a9563d8e551be3bf06
|
Loading…
Reference in a new issue