1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-12-23 15:49:44 -05:00

chore: upgrade deno_core to 0.249.0 (#22058)

This commit is contained in:
Bartek Iwańczuk 2024-01-23 22:56:56 +01:00 committed by GitHub
parent 5aa25f08be
commit 13d5c6420e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 50 additions and 33 deletions

16
Cargo.lock generated
View file

@ -1196,9 +1196,9 @@ dependencies = [
[[package]]
name = "deno_core"
version = "0.248.0"
version = "0.249.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "974d075b6647aa6cca14ea75c3833f8996b1c3e487adcde490977f21ac14e27e"
checksum = "02ed91e4f3a224de2a6d73211a5462e66c4394472873506a58e2c5377cf7105f"
dependencies = [
"anyhow",
"bit-set",
@ -1646,9 +1646,9 @@ dependencies = [
[[package]]
name = "deno_ops"
version = "0.124.0"
version = "0.125.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a1bc46bc85a26530e196a5f675dab6e06fb86b9104dc6fdc31cfc9ae1832d911"
checksum = "adc649e55c4fcd40b247dd1abdff2681e3b5c6331a6ab8d7900d885cd486a7c3"
dependencies = [
"proc-macro-rules",
"proc-macro2",
@ -5350,9 +5350,9 @@ dependencies = [
[[package]]
name = "serde_v8"
version = "0.157.0"
version = "0.158.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "8853e607c700ade0acb853aafda7e4cc1f752f4ebb35b0e2ecbf42e784e6d0e0"
checksum = "3035399dd0135f3c1a02e5fedd72d1c417dd3cd3107789ef9e3a4f657de4dd1d"
dependencies = [
"bytes",
"derive_more",
@ -7074,7 +7074,7 @@ dependencies = [
"codespan-reporting",
"log",
"naga",
"parking_lot 0.11.2",
"parking_lot 0.12.1",
"profiling",
"raw-window-handle",
"ron",
@ -7115,7 +7115,7 @@ dependencies = [
"naga",
"objc",
"once_cell",
"parking_lot 0.11.2",
"parking_lot 0.12.1",
"profiling",
"range-alloc",
"raw-window-handle",

View file

@ -42,7 +42,7 @@ repository = "https://github.com/denoland/deno"
[workspace.dependencies]
deno_ast = { version = "0.32.0", features = ["transpiling"] }
deno_core = { version = "0.248.0" }
deno_core = { version = "0.249.0" }
deno_runtime = { version = "0.140.0", path = "./runtime" }
napi_sym = { version = "0.62.0", path = "./cli/napi/sym" }

View file

@ -115,7 +115,17 @@ pub fn get_types_declaration_file_text() -> String {
}
fn get_asset_texts_from_new_runtime() -> Result<Vec<AssetText>, AnyError> {
deno_core::extension!(deno_cli_tsc, ops_fn = deno_ops);
deno_core::extension!(
deno_cli_tsc,
ops = [
op_create_hash,
op_emit,
op_is_node_file,
op_load,
op_resolve,
op_respond,
]
);
// the assets are stored within the typescript isolate, so take them out of there
let mut runtime = JsRuntime::new(RuntimeOptions {
@ -805,7 +815,14 @@ pub fn exec(request: Request) -> Result<Response, AnyError> {
.collect();
deno_core::extension!(deno_cli_tsc,
ops_fn = deno_ops,
ops = [
op_create_hash,
op_emit,
op_is_node_file,
op_load,
op_resolve,
op_respond,
],
options = {
request: Request,
root_map: HashMap<String, Url>,
@ -865,18 +882,6 @@ pub fn exec(request: Request) -> Result<Response, AnyError> {
}
}
deno_core::ops!(
deno_ops,
[
op_create_hash,
op_emit,
op_is_node_file,
op_load,
op_resolve,
op_respond,
]
);
#[cfg(test)]
mod tests {
use super::Diagnostic;

View file

@ -17,9 +17,9 @@ use std::env;
mod sys_info;
deno_core::ops!(
deno_ops,
[
deno_core::extension!(
deno_os,
ops = [
op_env,
op_exec_path,
op_exit,
@ -36,12 +36,7 @@ deno_core::ops!(
op_system_memory_info,
op_uid,
op_runtime_memory_usage,
]
);
deno_core::extension!(
deno_os,
ops_fn = deno_ops,
],
options = {
exit_code: ExitCode,
},
@ -52,7 +47,24 @@ deno_core::extension!(
deno_core::extension!(
deno_os_worker,
ops_fn = deno_ops,
ops = [
op_env,
op_exec_path,
op_exit,
op_delete_env,
op_get_env,
op_gid,
op_hostname,
op_loadavg,
op_network_interfaces,
op_os_release,
op_os_uptime,
op_set_env,
op_set_exit_code,
op_system_memory_info,
op_uid,
op_runtime_memory_usage,
],
middleware = |op| match op.name {
"op_exit" | "op_set_exit_code" =>
op.with_implementation_from(&deno_core::op_void_sync::DECL),