From 0a41727977af7dd8f530fe9f20e7b1980e199d53 Mon Sep 17 00:00:00 2001 From: Frank Rehwinkel Date: Mon, 22 Apr 2024 10:53:50 -0400 Subject: [PATCH 01/20] Cargo.toml dependencies: remove wasi-virt --- Cargo.lock | 501 +++++------------------------------------------------ Cargo.toml | 1 - 2 files changed, 45 insertions(+), 457 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 0c5aba4..9f29c83 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -8,7 +8,7 @@ version = "0.21.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8a30b2e23b9e17a9f90641c7ab1549cd9b44f296d3ccbf309d2863cfe398a0cb" dependencies = [ - "gimli 0.28.1", + "gimli", ] [[package]] @@ -121,7 +121,7 @@ checksum = "c980ee35e870bd1a4d2c8294d4c04d0499e67bca1e4b5cefcc693c2fa00caea9" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn", ] [[package]] @@ -335,10 +335,10 @@ version = "4.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "307bc0538d5f0f83b8248db3087aa92fe504e4691294d0c96c0eabc33f47ba47" dependencies = [ - "heck 0.4.1", + "heck", "proc-macro2", "quote", - "syn 2.0.48", + "syn", ] [[package]] @@ -356,16 +356,6 @@ dependencies = [ "error-code", ] -[[package]] -name = "codespan-reporting" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3538270d33cc669650c4b093848450d380def10c331d38c768e34cac80576e6e" -dependencies = [ - "termcolor", - "unicode-width", -] - [[package]] name = "colorchoice" version = "1.0.0" @@ -428,7 +418,7 @@ dependencies = [ "cranelift-control", "cranelift-entity", "cranelift-isle", - "gimli 0.28.1", + "gimli", "hashbrown 0.14.3", "log", "regalloc2", @@ -565,50 +555,6 @@ dependencies = [ "typenum", ] -[[package]] -name = "cxx" -version = "1.0.116" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8aff472b83efd22bfc0176aa8ba34617dd5c17364670eb201a5f06d339b8abf7" -dependencies = [ - "cc", - "cxxbridge-flags", - "cxxbridge-macro", - "link-cplusplus", -] - -[[package]] -name = "cxx-build" -version = "1.0.116" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bcf6e7a52c19013a9a0ec421c7d9c2d1125faf333551227e0a017288d71b47c3" -dependencies = [ - "cc", - "codespan-reporting", - "once_cell", - "proc-macro2", - "quote", - "scratch", - "syn 2.0.48", -] - -[[package]] -name = "cxxbridge-flags" -version = "1.0.116" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "589e83d02fc1d4fb78f5ad56ca08835341e23499d086d2821315869426d618dc" - -[[package]] -name = "cxxbridge-macro" -version = "1.0.116" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2cb1fd8ffae4230c7cfbbaf3698dbeaf750fa8c5dadf7ed897df581b9b572a5" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.48", -] - [[package]] name = "debugid" version = "0.8.0" @@ -735,24 +681,12 @@ version = "3.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "281e452d3bad4005426416cdba5ccfd4f5c1280e10099e21db27f7c1c28347fc" -[[package]] -name = "fallible-iterator" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4443176a9f2c162692bd3d352d745ef9413eec5782a80d8fd6f8a1ac692a07f7" - [[package]] name = "fallible-iterator" version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2acce4a10f12dc2fb14a218589d4f1f62ef011b2d0cc4b3cb1bba8e94da14649" -[[package]] -name = "fastrand" -version = "2.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25cbce373ec4653f1a01a31e8a5e5ec0c622dc27ff9c4e6606eefef5cbbed4a5" - [[package]] name = "fd-lock" version = "4.0.2" @@ -894,34 +828,17 @@ dependencies = [ "wasi", ] -[[package]] -name = "gimli" -version = "0.26.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22030e2c5a68ec659fde1e949a745124b48e6fa8b045b7ed5bd1fe4ccc5c4e5d" -dependencies = [ - "fallible-iterator 0.2.0", - "indexmap 1.9.3", - "stable_deref_trait", -] - [[package]] name = "gimli" version = "0.28.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4271d37baee1b8c7e4b708028c57d816cf9d2434acb33a549475f78c181f6253" dependencies = [ - "fallible-iterator 0.3.0", - "indexmap 2.1.0", + "fallible-iterator", + "indexmap", "stable_deref_trait", ] -[[package]] -name = "hashbrown" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" - [[package]] name = "hashbrown" version = "0.13.2" @@ -940,15 +857,6 @@ dependencies = [ "ahash", ] -[[package]] -name = "heck" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d621efb26863f0e9924c6ac577e8275e5e6b77455db64ffa6c65c904e9e132c" -dependencies = [ - "unicode-segmentation", -] - [[package]] name = "heck" version = "0.4.1" @@ -1029,16 +937,6 @@ dependencies = [ "version_check", ] -[[package]] -name = "indexmap" -version = "1.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd070e393353796e801d209ad339e89596eb4c8d430d18ede6a1cced8fafbd99" -dependencies = [ - "autocfg", - "hashbrown 0.12.3", -] - [[package]] name = "indexmap" version = "2.1.0" @@ -1154,15 +1052,6 @@ dependencies = [ "redox_syscall", ] -[[package]] -name = "link-cplusplus" -version = "1.0.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d240c6f7e1ba3a28b0249f774e6a9dd0175054b52dfbb61b16eb8505c3785c9" -dependencies = [ - "cc", -] - [[package]] name = "linux-raw-sys" version = "0.4.12" @@ -1299,7 +1188,7 @@ checksum = "a6a622008b6e321afc04970976f62ee297fdbaa6f95318ca343e3eebb9648441" dependencies = [ "crc32fast", "hashbrown 0.14.3", - "indexmap 2.1.0", + "indexmap", "memchr", ] @@ -1328,7 +1217,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e1d3afd2628e69da2be385eb6f2fd57c8ac7977ceeff6dc166ff1657b0e386a9" dependencies = [ "fixedbitset", - "indexmap 2.1.0", + "indexmap", ] [[package]] @@ -1540,12 +1429,6 @@ dependencies = [ "windows-sys 0.52.0", ] -[[package]] -name = "rustversion" -version = "1.0.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ffc183a10b4478d04cbbbfc96d0873219d962dd5accaff2ffbd4ceb7df837f4" - [[package]] name = "rustyline" version = "13.0.0" @@ -1574,12 +1457,6 @@ version = "1.0.16" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f98d2aa92eebf49b69786be48e4477826b256916e84a57ff2a4f21923b48eb4c" -[[package]] -name = "scratch" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3cf7c11c38cb994f3d40e8a8cde3bbd1f72a435e4c49e85d6553d8312306152" - [[package]] name = "semver" version = "1.0.21" @@ -1603,7 +1480,7 @@ checksum = "a3385e45322e8f9931410f01b3031ec534c3947d0e94c18049af4d9f9907d4e0" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn", ] [[package]] @@ -1617,22 +1494,13 @@ dependencies = [ "serde", ] -[[package]] -name = "serde_spanned" -version = "0.6.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb3622f419d1296904700073ea6cc23ad690adbd66f13ea683df73298736f0c1" -dependencies = [ - "serde", -] - [[package]] name = "serde_yaml" version = "0.9.30" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b1bf28c79a99f70ee1f1d83d10c875d2e70618417fda01ad1785e027579d9d38" dependencies = [ - "indexmap 2.1.0", + "indexmap", "itoa", "ryu", "serde", @@ -1718,36 +1586,6 @@ version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5ee073c9e4cd00e28217186dbe12796d692868f432bf2e97ee73bed0c56dfa01" -[[package]] -name = "strum" -version = "0.24.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "063e6045c0e62079840579a7e47a355ae92f60eb74daaf156fb1e84ba164e63f" - -[[package]] -name = "strum_macros" -version = "0.24.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e385be0d24f186b4ce2f9982191e7101bb737312ad61c1f2f984f34bcf85d59" -dependencies = [ - "heck 0.4.1", - "proc-macro2", - "quote", - "rustversion", - "syn 1.0.109", -] - -[[package]] -name = "syn" -version = "1.0.109" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - [[package]] name = "syn" version = "2.0.48" @@ -1781,28 +1619,6 @@ version = "0.12.13" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "69758bda2e78f098e4ccb393021a0963bb3442eac05f135c30f61b7370bbafae" -[[package]] -name = "tempfile" -version = "3.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01ce4141aa927a6d1bd34a041795abd0db1cccba5d5f24b009f694bdf3a1f3fa" -dependencies = [ - "cfg-if", - "fastrand", - "redox_syscall", - "rustix", - "windows-sys 0.52.0", -] - -[[package]] -name = "termcolor" -version = "1.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06794f8f6c5c898b3275aebefa6b8a1cb24cd2c6c79397ab15774837a0bc5755" -dependencies = [ - "winapi-util", -] - [[package]] name = "thiserror" version = "1.0.56" @@ -1820,7 +1636,7 @@ checksum = "fa0faa943b50f3db30a20aa7e265dbc66076993efed8463e8de414e5d06d3471" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn", ] [[package]] @@ -1863,7 +1679,7 @@ checksum = "5b8a1e28f2deaa14e508979454cb3a223b10b938b45af148bc0986de36f1923b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn", ] [[package]] @@ -1875,40 +1691,6 @@ dependencies = [ "serde", ] -[[package]] -name = "toml" -version = "0.8.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a9aad4a3066010876e8dcf5a8a06e70a558751117a145c6ce2b82c2e2054290" -dependencies = [ - "serde", - "serde_spanned", - "toml_datetime", - "toml_edit", -] - -[[package]] -name = "toml_datetime" -version = "0.6.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3550f4e9685620ac18a50ed434eb3aec30db8ba93b0287467bca5826ea25baf1" -dependencies = [ - "serde", -] - -[[package]] -name = "toml_edit" -version = "0.22.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99e68c159e8f5ba8a28c4eb7b0c0c190d77bb479047ca713270048145a9ad28a" -dependencies = [ - "indexmap 2.1.0", - "serde", - "serde_spanned", - "toml_datetime", - "winnow", -] - [[package]] name = "tracing" version = "0.1.40" @@ -1928,7 +1710,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn", ] [[package]] @@ -2020,34 +1802,6 @@ version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" -[[package]] -name = "walrus" -version = "0.20.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c03529cd0c4400a2449f640d2f27cd1b48c3065226d15e26d98e4429ab0adb7" -dependencies = [ - "anyhow", - "gimli 0.26.2", - "id-arena", - "leb128", - "log", - "walrus-macro", - "wasm-encoder 0.29.0", - "wasmparser 0.80.2", -] - -[[package]] -name = "walrus-macro" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0a6e5bd22c71e77d60140b0bd5be56155a37e5bd14e24f5f87298040d0cc40d7" -dependencies = [ - "heck 0.3.3", - "proc-macro2", - "quote", - "syn 1.0.109", -] - [[package]] name = "wasi" version = "0.11.0+wasi-snapshot-preview1" @@ -2081,22 +1835,6 @@ dependencies = [ "windows-sys 0.52.0", ] -[[package]] -name = "wasi-virt" -version = "0.1.0" -source = "git+https://github.com/bytecodealliance/WASI-Virt?rev=fd2fae04342ea58aab2426ca041da68be046b030#fd2fae04342ea58aab2426ca041da68be046b030" -dependencies = [ - "anyhow", - "clap", - "serde", - "toml 0.8.10", - "walrus", - "wasm-compose 0.5.5", - "wasm-metadata 0.10.20", - "wasm-opt", - "wit-component 0.21.0", -] - [[package]] name = "wasm-bindgen" version = "0.2.89" @@ -2118,7 +1856,7 @@ dependencies = [ "once_cell", "proc-macro2", "quote", - "syn 2.0.48", + "syn", "wasm-bindgen-shared", ] @@ -2140,7 +1878,7 @@ checksum = "f0eb82fcb7930ae6219a7ecfd55b217f5f0893484b7a13022ebb2b2bf20b5283" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn", "wasm-bindgen-backend", "wasm-bindgen-shared", ] @@ -2151,27 +1889,6 @@ version = "0.2.89" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7ab9b36309365056cd639da3134bf87fa8f3d86008abf99e612384a6eecd459f" -[[package]] -name = "wasm-compose" -version = "0.5.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd324927af875ebedb1b820c00e3c585992d33c2c787c5021fe6d8982527359b" -dependencies = [ - "anyhow", - "heck 0.4.1", - "im-rc", - "indexmap 2.1.0", - "log", - "petgraph", - "serde", - "serde_derive", - "serde_yaml", - "smallvec", - "wasm-encoder 0.41.2", - "wasmparser 0.121.2", - "wat", -] - [[package]] name = "wasm-compose" version = "0.201.0" @@ -2179,9 +1896,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "10501f9526fedb9592271a19c34257582b6abcb4636e276ee75cb95aa242ee2a" dependencies = [ "anyhow", - "heck 0.4.1", + "heck", "im-rc", - "indexmap 2.1.0", + "indexmap", "log", "petgraph", "serde", @@ -2193,15 +1910,6 @@ dependencies = [ "wat", ] -[[package]] -name = "wasm-encoder" -version = "0.29.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "18c41dbd92eaebf3612a39be316540b8377c871cb9bde6b064af962984912881" -dependencies = [ - "leb128", -] - [[package]] name = "wasm-encoder" version = "0.41.2" @@ -2209,7 +1917,6 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "972f97a5d8318f908dded23594188a90bcd09365986b1163e66d70170e5287ae" dependencies = [ "leb128", - "wasmparser 0.121.2", ] [[package]] @@ -2222,22 +1929,6 @@ dependencies = [ "wasmparser 0.201.0", ] -[[package]] -name = "wasm-metadata" -version = "0.10.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "18ebaa7bd0f9e7a5e5dd29b9a998acf21c4abed74265524dd7e85934597bfb10" -dependencies = [ - "anyhow", - "indexmap 2.1.0", - "serde", - "serde_derive", - "serde_json", - "spdx", - "wasm-encoder 0.41.2", - "wasmparser 0.121.2", -] - [[package]] name = "wasm-metadata" version = "0.201.0" @@ -2245,7 +1936,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0fd83062c17b9f4985d438603cde0a5e8c5c8198201a6937f778b607924c7da2" dependencies = [ "anyhow", - "indexmap 2.1.0", + "indexmap", "serde", "serde_derive", "serde_json", @@ -2254,52 +1945,6 @@ dependencies = [ "wasmparser 0.201.0", ] -[[package]] -name = "wasm-opt" -version = "0.116.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc942673e7684671f0c5708fc18993569d184265fd5223bb51fc8e5b9b6cfd52" -dependencies = [ - "anyhow", - "libc", - "strum", - "strum_macros", - "tempfile", - "thiserror", - "wasm-opt-cxx-sys", - "wasm-opt-sys", -] - -[[package]] -name = "wasm-opt-cxx-sys" -version = "0.116.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c57b28207aa724318fcec6575fe74803c23f6f266fce10cbc9f3f116762f12e" -dependencies = [ - "anyhow", - "cxx", - "cxx-build", - "wasm-opt-sys", -] - -[[package]] -name = "wasm-opt-sys" -version = "0.116.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a1cce564dc768dacbdb718fc29df2dba80bd21cb47d8f77ae7e3d95ceb98cbe" -dependencies = [ - "anyhow", - "cc", - "cxx", - "cxx-build", -] - -[[package]] -name = "wasmparser" -version = "0.80.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "449167e2832691a1bff24cde28d2804e90e09586a448c8e76984792c44334a6b" - [[package]] name = "wasmparser" version = "0.121.2" @@ -2307,7 +1952,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9dbe55c8f9d0dbd25d9447a5a889ff90c0cc3feaa7395310d3d826b2c703eaab" dependencies = [ "bitflags 2.4.1", - "indexmap 2.1.0", + "indexmap", "semver", ] @@ -2318,7 +1963,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "84e5df6dba6c0d7fafc63a450f1738451ed7a0b52295d83e868218fa286bf708" dependencies = [ "bitflags 2.4.1", - "indexmap 2.1.0", + "indexmap", "semver", ] @@ -2346,8 +1991,8 @@ dependencies = [ "cfg-if", "encoding_rs", "fxprof-processed-profile", - "gimli 0.28.1", - "indexmap 2.1.0", + "gimli", + "indexmap", "ittapi", "libc", "log", @@ -2400,7 +2045,7 @@ dependencies = [ "serde", "serde_derive", "sha2", - "toml 0.5.11", + "toml", "windows-sys 0.52.0", "zstd", ] @@ -2414,7 +2059,7 @@ dependencies = [ "anyhow", "proc-macro2", "quote", - "syn 2.0.48", + "syn", "wasmtime-component-util", "wasmtime-wit-bindgen", "wit-parser 0.13.2", @@ -2440,7 +2085,7 @@ dependencies = [ "cranelift-frontend", "cranelift-native", "cranelift-wasm", - "gimli 0.28.1", + "gimli", "log", "object", "target-lexicon", @@ -2461,7 +2106,7 @@ dependencies = [ "cranelift-codegen", "cranelift-control", "cranelift-native", - "gimli 0.28.1", + "gimli", "object", "target-lexicon", "wasmtime-environ", @@ -2477,8 +2122,8 @@ dependencies = [ "bincode", "cpp_demangle", "cranelift-entity", - "gimli 0.28.1", - "indexmap 2.1.0", + "gimli", + "indexmap", "log", "object", "rustc-demangle", @@ -2541,7 +2186,7 @@ dependencies = [ "cc", "cfg-if", "encoding_rs", - "indexmap 2.1.0", + "indexmap", "libc", "log", "mach", @@ -2582,7 +2227,7 @@ checksum = "8ef32eea9fc7035a55159a679d1e89b43ece5ae45d24eed4808e6a92c99a0da4" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn", ] [[package]] @@ -2626,7 +2271,7 @@ checksum = "db3378c0e808a744b5d4df2a9a9d2746a53b151811926731f04fc401707f7d54" dependencies = [ "anyhow", "cranelift-codegen", - "gimli 0.28.1", + "gimli", "object", "target-lexicon", "wasmparser 0.121.2", @@ -2642,8 +2287,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ca677c36869e45602617b25a9968ec0d895ad9a0aee3756d9dee1ddd89456f91" dependencies = [ "anyhow", - "heck 0.4.1", - "indexmap 2.1.0", + "heck", + "indexmap", "wit-parser 0.13.2", ] @@ -2700,11 +2345,10 @@ dependencies = [ "nom_locate", "rustyline", "tokio", - "wasi-virt", - "wasm-compose 0.201.0", + "wasm-compose", "wasmtime", "wasmtime-wasi", - "wit-component 0.201.0", + "wit-component", "wit-parser 0.201.0", ] @@ -2730,11 +2374,11 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0446357a5a7af0172848b6eca7b2aa1ab7d90065cd2ab02b633a322e1a52f636" dependencies = [ "anyhow", - "heck 0.4.1", + "heck", "proc-macro2", "quote", "shellexpand", - "syn 2.0.48", + "syn", "witx", ] @@ -2746,7 +2390,7 @@ checksum = "9498ef53a12cf25dc6de9baef6ccd8b58d159202c412a19f4d72b218393086c5" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn", "wiggle-generate", ] @@ -2766,15 +2410,6 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" -[[package]] -name = "winapi-util" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f29e6f9198ba0d26b4c9f07dbe6f9ed633e1f3d5b8b414090084349e46a52596" -dependencies = [ - "winapi", -] - [[package]] name = "winapi-x86_64-pc-windows-gnu" version = "0.4.0" @@ -2789,7 +2424,7 @@ checksum = "8197ed4a2ebf612f0624ddda10de71f8cd2d3a4ecf8ffac0586a264599708d63" dependencies = [ "anyhow", "cranelift-codegen", - "gimli 0.28.1", + "gimli", "regalloc2", "smallvec", "target-lexicon", @@ -2938,15 +2573,6 @@ version = "0.52.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "dff9641d1cd4be8d1a070daf9e3773c5f67e78b4d9d42263020c057706765c04" -[[package]] -name = "winnow" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6b1dbce9e90e5404c5a52ed82b1d13fc8cfbdad85033b6f57546ffd1265f8451" -dependencies = [ - "memchr", -] - [[package]] name = "winx" version = "0.36.3" @@ -2957,25 +2583,6 @@ dependencies = [ "windows-sys 0.52.0", ] -[[package]] -name = "wit-component" -version = "0.21.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be60cd1b2ff7919305301d0c27528d4867bd793afe890ba3837743da9655d91b" -dependencies = [ - "anyhow", - "bitflags 2.4.1", - "indexmap 2.1.0", - "log", - "serde", - "serde_derive", - "serde_json", - "wasm-encoder 0.41.2", - "wasm-metadata 0.10.20", - "wasmparser 0.121.2", - "wit-parser 0.14.0", -] - [[package]] name = "wit-component" version = "0.201.0" @@ -2984,13 +2591,13 @@ checksum = "421c0c848a0660a8c22e2fd217929a0191f14476b68962afd2af89fd22e39825" dependencies = [ "anyhow", "bitflags 2.4.1", - "indexmap 2.1.0", + "indexmap", "log", "serde", "serde_derive", "serde_json", "wasm-encoder 0.201.0", - "wasm-metadata 0.201.0", + "wasm-metadata", "wasmparser 0.201.0", "wit-parser 0.201.0", ] @@ -3003,7 +2610,7 @@ checksum = "316b36a9f0005f5aa4b03c39bc3728d045df136f8c13a73b7db4510dec725e08" dependencies = [ "anyhow", "id-arena", - "indexmap 2.1.0", + "indexmap", "log", "semver", "serde", @@ -3012,24 +2619,6 @@ dependencies = [ "unicode-xid", ] -[[package]] -name = "wit-parser" -version = "0.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ee4ad7310367bf272507c0c8e0c74a80b4ed586b833f7c7ca0b7588f686f11a" -dependencies = [ - "anyhow", - "id-arena", - "indexmap 2.1.0", - "log", - "semver", - "serde", - "serde_derive", - "serde_json", - "unicode-xid", - "wasmparser 0.121.2", -] - [[package]] name = "wit-parser" version = "0.201.0" @@ -3038,7 +2627,7 @@ checksum = "196d3ecfc4b759a8573bf86a9b3f8996b304b3732e4c7de81655f875f6efdca6" dependencies = [ "anyhow", "id-arena", - "indexmap 2.1.0", + "indexmap", "log", "semver", "serde", @@ -3077,7 +2666,7 @@ checksum = "9ce1b18ccd8e73a9321186f97e46f9f04b778851177567b1975109d26a08d2a6" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn", ] [[package]] diff --git a/Cargo.toml b/Cargo.toml index 00b8e63..9913cce 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -23,7 +23,6 @@ tokio = { version = "1.36.0", features = ["macros"] } wasmtime = { version = "18.0.1", features = ["component-model"] } wasmtime-wasi = { version = "18.0.2", features = ["tokio"] } -wasi-virt = { git = "https://github.com/bytecodealliance/WASI-Virt", rev = "fd2fae04342ea58aab2426ca041da68be046b030" } wit-component = "0.201.0" wit-parser = "0.201.0" wasm-compose = "0.201.0" From 893f775612d499b576032dddae8f23c70a00e923 Mon Sep 17 00:00:00 2001 From: Frank Rehwinkel Date: Mon, 22 Apr 2024 10:59:24 -0400 Subject: [PATCH 02/20] Cargo.lock versions: after `cargo update` --- Cargo.lock | 587 +++++++++++++++++++++++++++-------------------------- 1 file changed, 294 insertions(+), 293 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 9f29c83..b9f3726 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -19,9 +19,9 @@ checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" [[package]] name = "ahash" -version = "0.8.7" +version = "0.8.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77c3a9648d43b9cd48db467b3f87fdd6e146bcc88ab0180006cef2179fe11d01" +checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" dependencies = [ "cfg-if", "once_cell", @@ -31,9 +31,9 @@ dependencies = [ [[package]] name = "aho-corasick" -version = "1.1.2" +version = "1.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2969dcb958b36655471fc61f7e416fa76033bdd4bfed0678d8fee1e2d07a1f0" +checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" dependencies = [ "memchr", ] @@ -55,9 +55,9 @@ dependencies = [ [[package]] name = "anstream" -version = "0.6.11" +version = "0.6.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e2e1ebcb11de5c03c67de28a7df593d32191b44939c482e97702baaaa6ab6a5" +checksum = "d96bd03f33fe50a863e394ee9718a706f988b9079b20c3784fb726e7678b62fb" dependencies = [ "anstyle", "anstyle-parse", @@ -69,9 +69,9 @@ dependencies = [ [[package]] name = "anstyle" -version = "1.0.4" +version = "1.0.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7079075b41f533b8c61d2a4d073c4676e1f8b249ff94a393b0595db304e0dd87" +checksum = "8901269c6307e8d93993578286ac0edf7f195079ffff5ebdeea6a59ffb7e36bc" [[package]] name = "anstyle-parse" @@ -103,9 +103,9 @@ dependencies = [ [[package]] name = "anyhow" -version = "1.0.79" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "080e9890a082662b09c1ad45f567faeeb47f22b5fb23895fbe1e651e718e25ca" +checksum = "f538837af36e6f6a9be0faa67f9a314f8119e4e4b5867c6ab40ed60360142519" [[package]] name = "arbitrary" @@ -115,9 +115,9 @@ checksum = "7d5a26814d8dcb93b0e5a0ff3c6d80a8843bafb21b39e8e18a6f05471870e110" [[package]] name = "async-trait" -version = "0.1.77" +version = "0.1.80" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c980ee35e870bd1a4d2c8294d4c04d0499e67bca1e4b5cefcc693c2fa00caea9" +checksum = "c6fa2087f2753a7da8cc1c0dbfcf89579dd57458e36769de5ac750b4671737ca" dependencies = [ "proc-macro2", "quote", @@ -126,15 +126,15 @@ dependencies = [ [[package]] name = "autocfg" -version = "1.1.0" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "f1fdabc7756949593fe60f30ec81974b613357de856987752631dea1e3394c80" [[package]] name = "backtrace" -version = "0.3.69" +version = "0.3.71" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2089b7e3f35b9dd2d0ed921ead4f6d318c27680d4a5bd167b3ee120edb105837" +checksum = "26b05800d2e817c8b3b4b54abd461726265fa9789ae34330622f2db9ee696f9d" dependencies = [ "addr2line", "cc", @@ -147,9 +147,9 @@ dependencies = [ [[package]] name = "base64" -version = "0.21.5" +version = "0.21.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35636a1494ede3b646cc98f74f8e62c773a38a659ebc777a2cf26b9b74171df9" +checksum = "9d297deb1925b89f2ccc13d7635fa0714f12c87adce1c75356b39ca9b7178567" [[package]] name = "bincode" @@ -162,15 +162,9 @@ dependencies = [ [[package]] name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - -[[package]] -name = "bitflags" -version = "2.4.1" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "bitmaps" @@ -192,15 +186,15 @@ dependencies = [ [[package]] name = "bumpalo" -version = "3.14.0" +version = "3.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f30e7476521f6f8af1a1c4c0b8cc94f0bee37d91763d0ca2665f299b6cd8aec" +checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c" [[package]] name = "bytecount" -version = "0.6.7" +version = "0.6.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1e5f035d16fc623ae5f74981db80a439803888314e3a555fd6f04acd51a3205" +checksum = "5ce89b21cab1437276d2650d57e971f9d548a2d9037cc231abdc0562b97498ce" [[package]] name = "byteorder" @@ -210,9 +204,9 @@ checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" [[package]] name = "bytes" -version = "1.5.0" +version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2bd12c1caf447e69cd4528f47f94d203fd2582878ecb9e9465484c4148a8223" +checksum = "514de17de45fdb8dc022b1a7975556c53c86f9f0aa5f534b98977b171857c2c9" [[package]] name = "cap-fs-ext" @@ -293,12 +287,13 @@ dependencies = [ [[package]] name = "cc" -version = "1.0.83" +version = "1.0.95" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1174fb0b6ec23863f8b971027804a42614e347eafb0a95bf0b12cdae21fc4d0" +checksum = "d32a725bc159af97c3e629873bb9f88fb8cf8a4867175f76dc987815ea07c83b" dependencies = [ "jobserver", "libc", + "once_cell", ] [[package]] @@ -309,9 +304,9 @@ checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" [[package]] name = "clap" -version = "4.5.0" +version = "4.5.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "80c21025abd42669a92efc996ef13cfb2c5c627858421ea58d5c3b331a6c134f" +checksum = "90bc066a67923782aa8515dbaea16946c5bcc5addbd668bb80af688e53e548a0" dependencies = [ "clap_builder", "clap_derive", @@ -319,9 +314,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.5.0" +version = "4.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "458bf1f341769dfcf849846f65dffdf9146daa56bcd2a47cb4e1de9915567c99" +checksum = "ae129e2e766ae0ec03484e609954119f123cc1fe650337e155d03b022f24f7b4" dependencies = [ "anstream", "anstyle", @@ -331,11 +326,11 @@ dependencies = [ [[package]] name = "clap_derive" -version = "4.5.0" +version = "4.5.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "307bc0538d5f0f83b8248db3087aa92fe504e4691294d0c96c0eabc33f47ba47" +checksum = "528131438037fd55894f62d6e9f068b8f45ac57ffa77517819645d10aed04f64" dependencies = [ - "heck", + "heck 0.5.0", "proc-macro2", "quote", "syn", @@ -349,9 +344,9 @@ checksum = "98cc8fbded0c607b7ba9dd60cd98df59af97e84d24e49c8557331cfc26d301ce" [[package]] name = "clipboard-win" -version = "5.0.0" +version = "5.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c57002a5d9be777c1ef967e33674dac9ebd310d8893e4e3437b14d5f0f6372cc" +checksum = "79f4473f5144e20d9aceaf2972478f06ddf687831eafeeb434fbaf0acc4144ad" dependencies = [ "error-code", ] @@ -398,18 +393,18 @@ dependencies = [ [[package]] name = "cranelift-bforest" -version = "0.105.2" +version = "0.105.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9515fcc42b6cb5137f76b84c1a6f819782d0cf12473d145d3bc5cd67eedc8bc2" +checksum = "496c993b62bdfbe9b4c518b8b3e1fdba9f89ef89fcccc050ab61d91dfba9fbaf" dependencies = [ "cranelift-entity", ] [[package]] name = "cranelift-codegen" -version = "0.105.2" +version = "0.105.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ad827c6071bfe6d22de1bc331296a29f9ddc506ff926d8415b435ec6a6efce0" +checksum = "96b922abb6be41fc383f5e9da65b58d32d0d0a32c87dfe3bbbcb61a09119506c" dependencies = [ "bumpalo", "cranelift-bforest", @@ -428,33 +423,33 @@ dependencies = [ [[package]] name = "cranelift-codegen-meta" -version = "0.105.2" +version = "0.105.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "10e6b36237a9ca2ce2fb4cc7741d418a080afa1327402138412ef85d5367bef1" +checksum = "634c2ed9ef8a04ca42535a3e2e7917e4b551f2f306f4df2d935a6e71e346c167" dependencies = [ "cranelift-codegen-shared", ] [[package]] name = "cranelift-codegen-shared" -version = "0.105.2" +version = "0.105.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c36bf4bfb86898a94ccfa773a1f86e8a5346b1983ff72059bdd2db4600325251" +checksum = "00cde1425b4da28bb0d5ff010030ea9cc9be7aded342ae099b394284f17cefce" [[package]] name = "cranelift-control" -version = "0.105.2" +version = "0.105.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7cbf36560e7a6bd1409ca91e7b43b2cc7ed8429f343d7605eadf9046e8fac0d0" +checksum = "1622125c99f1864aaf44e57971770c4a918d081d4b4af0bb597bdf624660ed66" dependencies = [ "arbitrary", ] [[package]] name = "cranelift-entity" -version = "0.105.2" +version = "0.105.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a71e11061a75b1184c09bea97c026a88f08b59ade96a7bb1f259d4ea0df2e942" +checksum = "ea97887aca1c0cbe7f8513874dc3603e9744fb1cfa78840ca8897bd2766bd35b" dependencies = [ "serde", "serde_derive", @@ -462,9 +457,9 @@ dependencies = [ [[package]] name = "cranelift-frontend" -version = "0.105.2" +version = "0.105.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af5d4da63143ee3485c7bcedde0a818727d737d1083484a0ceedb8950c89e495" +checksum = "4cdade4c14183fe41482071ed77d6a38cb95a17c7a0a05e629152e6292c4f8cb" dependencies = [ "cranelift-codegen", "log", @@ -474,15 +469,15 @@ dependencies = [ [[package]] name = "cranelift-isle" -version = "0.105.2" +version = "0.105.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "457a9832b089e26f5eea70dcf49bed8ec6edafed630ce7c83161f24d46ab8085" +checksum = "dbbe4d3ad7bd4bf4a8d916c8460b441cf92417f5cdeacce4dd1d96eee70b18a2" [[package]] name = "cranelift-native" -version = "0.105.2" +version = "0.105.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b490d579df1ce365e1ea359e24ed86d82289fa785153327c2f6a69a59a731e4" +checksum = "c46be4ed1fc8f36df4e2a442b8c30a39d8c03c1868182978f4c04ba2c25c9d4f" dependencies = [ "cranelift-codegen", "libc", @@ -491,9 +486,9 @@ dependencies = [ [[package]] name = "cranelift-wasm" -version = "0.105.2" +version = "0.105.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8cd747ed7f9a461dda9c388415392f6bb95d1a6ef3b7694d17e0817eb74b7798" +checksum = "a1d4c4a785a7866da89d20df159e3c4f96a5f14feb83b1f5998cfd5fe2e74d06" dependencies = [ "cranelift-codegen", "cranelift-entity", @@ -507,43 +502,37 @@ dependencies = [ [[package]] name = "crc32fast" -version = "1.3.2" +version = "1.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b540bd8bc810d3885c6ea91e2018302f68baba2129ab3e88f32389ee9370880d" +checksum = "b3855a8a784b474f333699ef2bbca9db2c4a1f6d9088a90a2d25b1eb53111eaa" dependencies = [ "cfg-if", ] [[package]] name = "crossbeam-deque" -version = "0.8.4" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fca89a0e215bab21874660c67903c5f143333cab1da83d041c7ded6053774751" +checksum = "613f8cc01fe9cf1a3eb3d7f488fd2fa8388403e97039e2f73692932e291a770d" dependencies = [ - "cfg-if", "crossbeam-epoch", "crossbeam-utils", ] [[package]] name = "crossbeam-epoch" -version = "0.9.17" +version = "0.9.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0e3681d554572a651dda4186cd47240627c3d0114d45a95f6ad27f2f22e7548d" +checksum = "5b82ac4a3c2ca9c3460964f020e1402edd5753411d7737aa39c3714ad1b5420e" dependencies = [ - "autocfg", - "cfg-if", "crossbeam-utils", ] [[package]] name = "crossbeam-utils" -version = "0.8.18" +version = "0.8.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3a430a770ebd84726f584a90ee7f020d28db52c6d02138900f22341f866d39c" -dependencies = [ - "cfg-if", -] +checksum = "248e3bacc7dc6baa3b21e405ee045c3047101a49145e7e9eca583ab4c2ca5345" [[package]] name = "crypto-common" @@ -617,15 +606,15 @@ dependencies = [ [[package]] name = "either" -version = "1.9.0" +version = "1.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +checksum = "a47c1c47d2f5964e29c61246e81db715514cd532db6b5116a25ea3c03d6780a2" [[package]] name = "encoding_rs" -version = "0.8.33" +version = "0.8.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7268b386296a025e474d5140678f75d6de9493ae55a5d709eeb9dd08149945e1" +checksum = "b45de904aa0b010bce2ab45264d0631681847fa7b6f2eaa7dab7619943bc4f59" dependencies = [ "cfg-if", ] @@ -648,9 +637,9 @@ dependencies = [ [[package]] name = "env_logger" -version = "0.11.1" +version = "0.11.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05e7cf40684ae96ade6232ed84582f40ce0a66efcd43a5117aef610534f8e0b8" +checksum = "38b35839ba51819680ba087cd351788c9a3c476841207e0b8cee0b04722343b9" dependencies = [ "anstream", "anstyle", @@ -677,9 +666,9 @@ dependencies = [ [[package]] name = "error-code" -version = "3.0.0" +version = "3.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "281e452d3bad4005426416cdba5ccfd4f5c1280e10099e21db27f7c1c28347fc" +checksum = "a0474425d51df81997e2f90a21591180b38eccf27292d755f3e30750225c175b" [[package]] name = "fallible-iterator" @@ -800,7 +789,7 @@ version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "27d12c0aed7f1e24276a241aadc4cb8ea9f83000f34bc062b7cc2d51e3b0fabd" dependencies = [ - "bitflags 2.4.1", + "bitflags", "debugid", "fxhash", "serde", @@ -819,9 +808,9 @@ dependencies = [ [[package]] name = "getrandom" -version = "0.2.11" +version = "0.2.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe9006bed769170c11f845cf00c7c1e9092aeb3f268e007c3e760ac68008070f" +checksum = "94b22e06ecb0110981051723910cbf0b5f5e09a2062dd7663334ee79a9d1286c" dependencies = [ "cfg-if", "libc", @@ -863,11 +852,17 @@ version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" +[[package]] +name = "heck" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" + [[package]] name = "hermit-abi" -version = "0.3.3" +version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d77f7ec81a6d05a3abb01ab6eb7590f6083d08449fe5a1c8b1e620283546ccb7" +checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" [[package]] name = "home" @@ -939,9 +934,9 @@ dependencies = [ [[package]] name = "indexmap" -version = "2.1.0" +version = "2.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d530e1a18b1cb4c484e6e34556a0d948706958449fca0cab753d649f2bce3d1f" +checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" dependencies = [ "equivalent", "hashbrown 0.14.3", @@ -950,9 +945,9 @@ dependencies = [ [[package]] name = "io-extras" -version = "0.18.1" +version = "0.18.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c301e73fb90e8a29e600a9f402d095765f74310d582916a952f618836a1bd1ed" +checksum = "c9f046b9af244f13b3bd939f55d16830ac3a201e8a9ba9661bfcb03e2be72b9b" dependencies = [ "io-lifetimes", "windows-sys 0.52.0", @@ -981,9 +976,9 @@ dependencies = [ [[package]] name = "itoa" -version = "1.0.10" +version = "1.0.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1a46d1a171d865aa5f83f92695765caa047a9b4cbae2cbf37dbd613a793fd4c" +checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" [[package]] name = "ittapi" @@ -1007,18 +1002,18 @@ dependencies = [ [[package]] name = "jobserver" -version = "0.1.27" +version = "0.1.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c37f63953c4c63420ed5fd3d6d398c719489b9f872b9fa683262f8edd363c7d" +checksum = "d2b099aaa34a9751c5bf0878add70444e1ed2dd73f347be99003d4577277de6e" dependencies = [ "libc", ] [[package]] name = "js-sys" -version = "0.3.66" +version = "0.3.69" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cee9c64da59eae3b50095c18d3e74f8b73c0b86d2792824ff01bbce68ba229ca" +checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d" dependencies = [ "wasm-bindgen", ] @@ -1037,32 +1032,31 @@ checksum = "884e2677b40cc8c339eaefcb701c32ef1fd2493d71118dc0ca4b6a736c93bd67" [[package]] name = "libc" -version = "0.2.151" +version = "0.2.153" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "302d7ab3130588088d277783b1e2d2e10c9e9e4a16dd9050e6ec93fb3e7048f4" +checksum = "9c198f91728a82281a64e1f4f9eeb25d82cb32a5de251c6bd1b5154d63a8e7bd" [[package]] name = "libredox" -version = "0.0.1" +version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85c833ca1e66078851dba29046874e38f08b2c883700aa29a03ddd3b23814ee8" +checksum = "c0ff37bd590ca25063e35af745c343cb7a0271906fb7b37e4813e8f79f00268d" dependencies = [ - "bitflags 2.4.1", + "bitflags", "libc", - "redox_syscall", ] [[package]] name = "linux-raw-sys" -version = "0.4.12" +version = "0.4.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4cd1a83af159aa67994778be9070f0ae1bd732942279cabb14f86f986a21456" +checksum = "01cda141df6706de531b6c46c3a33ecca755538219bd484262fa09410c13539c" [[package]] name = "log" -version = "0.4.20" +version = "0.4.21" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5e6163cb8c49088c2c36f57875e58ccd8c87c7427f7fbd50ea6710b2f3f2e8f" +checksum = "90ed8c1e510134f979dbc4f070f87d4313098b704861a105fe34231c70a3901c" [[package]] name = "mach" @@ -1081,9 +1075,9 @@ checksum = "4facc753ae494aeb6e3c22f839b158aebd4f9270f55cd3c79906c45476c47ab4" [[package]] name = "memchr" -version = "2.7.1" +version = "2.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "523dc4f511e55ab87b694dc30d0f820d60906ef06413f93d4d7a1385599cc149" +checksum = "6c8640c5d730cb13ebd907d8d04b52f55ac9a2eec55b440c8892f40d56c76c1d" [[package]] name = "memfd" @@ -1096,9 +1090,9 @@ dependencies = [ [[package]] name = "memoffset" -version = "0.9.0" +version = "0.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a634b1c61a95585bd15607c6ab0c4e5b226e695ff2800ba0cdccddf208c406c" +checksum = "488016bfae457b036d996092f6cb448677611ce4449e970ceaf42695203f218a" dependencies = [ "autocfg", ] @@ -1111,18 +1105,18 @@ checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" [[package]] name = "miniz_oxide" -version = "0.7.1" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7810e0be55b428ada41041c41f32c9f1a42817901b4ccf45fa3d4b6561e74c7" +checksum = "9d811f3e15f28568be3407c8e7fdb6514c1cda3cb30683f15b6a1a1dc4ea14a7" dependencies = [ "adler", ] [[package]] name = "mio" -version = "0.8.10" +version = "0.8.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f3d0b296e374a4e6f3c7b0a1f5a51d748a0d34c85e7dc48fc3fa9a87657fe09" +checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" dependencies = [ "libc", "wasi", @@ -1144,7 +1138,7 @@ version = "0.27.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2eb04e9c688eff1c89d72b407f168cf79bb9e867a9d3323ed6c01519eb9cc053" dependencies = [ - "bitflags 2.4.1", + "bitflags", "cfg-if", "libc", ] @@ -1222,9 +1216,9 @@ dependencies = [ [[package]] name = "pin-project-lite" -version = "0.2.13" +version = "0.2.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8afb450f006bf6385ca15ef45d71d2288452bc3683ce2e2cacc0d18e4be60b58" +checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" [[package]] name = "pin-utils" @@ -1234,9 +1228,9 @@ checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" [[package]] name = "pkg-config" -version = "0.3.28" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "69d3587f8a9e599cc7ec2c00e331f71c4e69a5f9a4b8a6efd5b07466b9736f9a" +checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" [[package]] name = "ppv-lite86" @@ -1246,9 +1240,9 @@ checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.81" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "3d1597b0c024618f09a9c3b8655b7e430397a36d23fdafec26d6965e9eec3eba" dependencies = [ "unicode-ident", ] @@ -1264,9 +1258,9 @@ dependencies = [ [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -1322,9 +1316,9 @@ dependencies = [ [[package]] name = "rayon" -version = "1.8.0" +version = "1.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c27db03db7734835b3f53954b534c91069375ce6ccaa2e065441e07d9b6cdb1" +checksum = "b418a60154510ca1a002a752ca9714984e21e4241e804d32555251faf8b78ffa" dependencies = [ "either", "rayon-core", @@ -1332,28 +1326,19 @@ dependencies = [ [[package]] name = "rayon-core" -version = "1.12.0" +version = "1.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ce3fb6ad83f861aac485e76e1985cd109d9a3713802152be56c3b1f0e0658ed" +checksum = "1465873a3dfdaa8ae7cb14b4383657caab0b3e8a0aa9ae8e04b044854c8dfce2" dependencies = [ "crossbeam-deque", "crossbeam-utils", ] -[[package]] -name = "redox_syscall" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4722d768eff46b75989dd134e5c353f0d6296e5aaa3132e776cbdb56be7731aa" -dependencies = [ - "bitflags 1.3.2", -] - [[package]] name = "redox_users" -version = "0.4.4" +version = "0.4.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a18479200779601e498ada4e8c1e1f50e3ee19deb0259c25825a98b5603b2cb4" +checksum = "bd283d9651eeda4b2a83a43c1c91b266c40fd76ecd39a50a8c630ae69dc72891" dependencies = [ "getrandom", "libredox", @@ -1375,9 +1360,9 @@ dependencies = [ [[package]] name = "regex" -version = "1.10.2" +version = "1.10.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "380b951a9c5e80ddfd6136919eef32310721aa4aacd4889a8d39124b026ab343" +checksum = "c117dbdfde9c8308975b6a18d71f3f385c89461f7b3fb054288ecf2a2058ba4c" dependencies = [ "aho-corasick", "memchr", @@ -1387,9 +1372,9 @@ dependencies = [ [[package]] name = "regex-automata" -version = "0.4.3" +version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f804c7828047e88b2d32e2d7fe5a105da8ee3264f01902f796c8e067dc2483f" +checksum = "86b83b8b9847f9bf95ef68afb0b8e6cdb80f498442f5179a29fad448fcc1eaea" dependencies = [ "aho-corasick", "memchr", @@ -1398,9 +1383,9 @@ dependencies = [ [[package]] name = "regex-syntax" -version = "0.8.2" +version = "0.8.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c08c74e62047bb2de4ff487b251e4a92e24f48745648451635cec7d591162d9f" +checksum = "adad44e29e4c806119491a7f06f03de4d1af22c3a680dd47f1e6e179439d1f56" [[package]] name = "rustc-demangle" @@ -1416,11 +1401,11 @@ checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2" [[package]] name = "rustix" -version = "0.38.28" +version = "0.38.33" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72e572a5e8ca657d7366229cdde4bd14c4eb5499a9573d4d366fe1b599daa316" +checksum = "e3cc72858054fcff6d7dea32df2aeaee6a7c24227366d7ea429aada2f26b16ad" dependencies = [ - "bitflags 2.4.1", + "bitflags", "errno", "itoa", "libc", @@ -1435,7 +1420,7 @@ version = "13.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "02a2d683a4ac90aeef5b1013933f6d977bd37d51ff3f4dad829d4931a7e6be86" dependencies = [ - "bitflags 2.4.1", + "bitflags", "cfg-if", "clipboard-win", "fd-lock", @@ -1453,30 +1438,30 @@ dependencies = [ [[package]] name = "ryu" -version = "1.0.16" +version = "1.0.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f98d2aa92eebf49b69786be48e4477826b256916e84a57ff2a4f21923b48eb4c" +checksum = "e86697c916019a8588c99b5fac3cead74ec0b4b819707a682fd4d23fa0ce1ba1" [[package]] name = "semver" -version = "1.0.21" +version = "1.0.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b97ed7a9823b74f99c7742f5336af7be5ecd3eeafcb1507d1fa93347b1d589b0" +checksum = "92d43fe69e652f3df9bdc2b85b2854a0825b86e4fb76bc44d945137d053639ca" [[package]] name = "serde" -version = "1.0.194" +version = "1.0.198" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b114498256798c94a0689e1a15fec6005dee8ac1f41de56404b67afc2a4b773" +checksum = "9846a40c979031340571da2545a4e5b7c4163bdae79b301d5f86d03979451fcc" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.194" +version = "1.0.198" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3385e45322e8f9931410f01b3031ec534c3947d0e94c18049af4d9f9907d4e0" +checksum = "e88edab869b01783ba905e7d0153f9fc1a6505a96e4ad3018011eedb838566d9" dependencies = [ "proc-macro2", "quote", @@ -1485,9 +1470,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.111" +version = "1.0.116" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "176e46fa42316f18edd598015a5166857fc835ec732f5215eac6b7bdbf0a84f4" +checksum = "3e17db7126d17feb94eb3fad46bf1a96b034e8aacbc2e775fe81505f8b0b2813" dependencies = [ "itoa", "ryu", @@ -1496,9 +1481,9 @@ dependencies = [ [[package]] name = "serde_yaml" -version = "0.9.30" +version = "0.9.34+deprecated" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1bf28c79a99f70ee1f1d83d10c875d2e70618417fda01ad1785e027579d9d38" +checksum = "6a8b1a1a2ebf674015cc02edccce75287f1a0130d394307b36743c2f5d504b47" dependencies = [ "indexmap", "itoa", @@ -1545,25 +1530,25 @@ checksum = "826167069c09b99d56f31e9ae5c99049e932a98c9dc2dac47645b08dbbf76ba7" [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "socket2" -version = "0.5.5" +version = "0.5.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b5fac59a5cb5dd637972e5fca70daf0523c9067fcdc4842f053dae04a18f8e9" +checksum = "05ffd9c0a93b7543e062e759284fcf5f5e3b098501104bfbdde4d404db792871" dependencies = [ "libc", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] name = "spdx" -version = "0.10.3" +version = "0.10.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62bde1398b09b9f93fc2fc9b9da86e362693e999d3a54a8ac47a99a5a73f638b" +checksum = "29ef1a0fa1e39ac22972c8db23ff89aea700ab96aa87114e1fb55937a631a0c9" dependencies = [ "smallvec", ] @@ -1582,15 +1567,15 @@ checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3" [[package]] name = "strsim" -version = "0.11.0" +version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ee073c9e4cd00e28217186dbe12796d692868f432bf2e97ee73bed0c56dfa01" +checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.60" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "909518bc7b1c9b779f1bbf07f2929d35af9f0f37e47c6e9ef7f9dddc1e1821f3" dependencies = [ "proc-macro2", "quote", @@ -1603,7 +1588,7 @@ version = "0.26.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0682e006dd35771e392a6623ac180999a9a854b1d4a6c12fb2e804941c2b1f58" dependencies = [ - "bitflags 2.4.1", + "bitflags", "cap-fs-ext", "cap-std", "fd-lock", @@ -1615,24 +1600,24 @@ dependencies = [ [[package]] name = "target-lexicon" -version = "0.12.13" +version = "0.12.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "69758bda2e78f098e4ccb393021a0963bb3442eac05f135c30f61b7370bbafae" +checksum = "e1fc403891a21bcfb7c37834ba66a547a8f402146eba7265b5a6d88059c9ff2f" [[package]] name = "thiserror" -version = "1.0.56" +version = "1.0.59" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d54378c645627613241d077a3a79db965db602882668f9136ac42af9ecb730ad" +checksum = "f0126ad08bff79f29fc3ae6a55cc72352056dfff61e3ff8bb7129476d44b23aa" dependencies = [ "thiserror-impl", ] [[package]] name = "thiserror-impl" -version = "1.0.56" +version = "1.0.59" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa0faa943b50f3db30a20aa7e265dbc66076993efed8463e8de414e5d06d3471" +checksum = "d1cd413b5d558b4c5bf3680e324a6fa5014e7b7c067a51e69dbdf47eb7148b66" dependencies = [ "proc-macro2", "quote", @@ -1656,9 +1641,9 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "tokio" -version = "1.36.0" +version = "1.37.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61285f6515fa018fb2d1e46eb21223fff441ee8db5d0f1435e8ab4f5cdb80931" +checksum = "1adbebffeca75fcfd058afa480fb6c0b81e165a0323f9c9d39c9697e37c46787" dependencies = [ "backtrace", "bytes", @@ -1730,9 +1715,9 @@ checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" [[package]] name = "unicode-bidi" -version = "0.3.14" +version = "0.3.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f2528f27a9eb2b21e69c95319b30bd0efd85d09c379741b0f78ea1d86be2416" +checksum = "08f95100a766bf4f8f28f90d77e0a5461bbdb219042e7679bebe79004fed8d75" [[package]] name = "unicode-ident" @@ -1742,18 +1727,18 @@ checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" [[package]] name = "unicode-normalization" -version = "0.1.22" +version = "0.1.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" +checksum = "a56d1686db2308d901306f92a263857ef59ea39678a5458e7cb17f01415101f5" dependencies = [ "tinyvec", ] [[package]] name = "unicode-segmentation" -version = "1.10.1" +version = "1.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1dd624098567895118886609431a7c3b8f516e41d30e0643f03d94592a147e36" +checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" [[package]] name = "unicode-width" @@ -1769,9 +1754,9 @@ checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c" [[package]] name = "unsafe-libyaml" -version = "0.2.10" +version = "0.2.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ab4c90930b95a82d00dc9e9ac071b4991924390d46cbd0dfe566148667605e4b" +checksum = "673aac59facbab8a9007c7f6108d11f63b603f7cabff99fabf650fea5c32b861" [[package]] name = "url" @@ -1792,9 +1777,9 @@ checksum = "711b9620af191e0cdc7468a8d14e709c3dcdb115b36f838e601583af800a370a" [[package]] name = "uuid" -version = "1.6.1" +version = "1.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e395fcf16a7a3d8127ec99782007af141946b4795001f876d54fb0d55978560" +checksum = "a183cf7feeba97b4dd1c0d46788634f6221d87fa961b305bed08c851829efcc0" [[package]] name = "version_check" @@ -1810,12 +1795,12 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasi-common" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "880c1461417b2bf90262591bf8a5f04358fb86dac8a585a49b87024971296763" +checksum = "5ce5d3e7e6f0fabe518a9bea9c803081544ef38d986f04d7f86737faed32d2ae" dependencies = [ "anyhow", - "bitflags 2.4.1", + "bitflags", "cap-fs-ext", "cap-rand", "cap-std", @@ -1837,9 +1822,9 @@ dependencies = [ [[package]] name = "wasm-bindgen" -version = "0.2.89" +version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ed0d4f68a3015cc185aff4db9506a015f4b96f95303897bfa23f846db54064e" +checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8" dependencies = [ "cfg-if", "wasm-bindgen-macro", @@ -1847,9 +1832,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-backend" -version = "0.2.89" +version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b56f625e64f3a1084ded111c4d5f477df9f8c92df113852fa5a374dbda78826" +checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da" dependencies = [ "bumpalo", "log", @@ -1862,9 +1847,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.89" +version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0162dbf37223cd2afce98f3d0785506dcb8d266223983e4b5b525859e6e182b2" +checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -1872,9 +1857,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.89" +version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0eb82fcb7930ae6219a7ecfd55b217f5f0893484b7a13022ebb2b2bf20b5283" +checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" dependencies = [ "proc-macro2", "quote", @@ -1885,9 +1870,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-shared" -version = "0.2.89" +version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ab9b36309365056cd639da3134bf87fa8f3d86008abf99e612384a6eecd459f" +checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" [[package]] name = "wasm-compose" @@ -1896,7 +1881,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "10501f9526fedb9592271a19c34257582b6abcb4636e276ee75cb95aa242ee2a" dependencies = [ "anyhow", - "heck", + "heck 0.4.1", "im-rc", "indexmap", "log", @@ -1929,6 +1914,15 @@ dependencies = [ "wasmparser 0.201.0", ] +[[package]] +name = "wasm-encoder" +version = "0.205.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90e95b3563d164f33c1cfb0a7efbd5940c37710019be10cd09f800fdec8b0e5c" +dependencies = [ + "leb128", +] + [[package]] name = "wasm-metadata" version = "0.201.0" @@ -1951,7 +1945,7 @@ version = "0.121.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9dbe55c8f9d0dbd25d9447a5a889ff90c0cc3feaa7395310d3d826b2c703eaab" dependencies = [ - "bitflags 2.4.1", + "bitflags", "indexmap", "semver", ] @@ -1962,7 +1956,7 @@ version = "0.201.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "84e5df6dba6c0d7fafc63a450f1738451ed7a0b52295d83e868218fa286bf708" dependencies = [ - "bitflags 2.4.1", + "bitflags", "indexmap", "semver", ] @@ -1979,9 +1973,9 @@ dependencies = [ [[package]] name = "wasmtime" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c843b8bc4dd4f3a76173ba93405c71111d570af0d90ea5f6299c705d0c2add2" +checksum = "69472708b96ee90579a482bdbb908ce97e53a9e5ebbcab59cc29c3977bcab512" dependencies = [ "addr2line", "anyhow", @@ -2023,18 +2017,18 @@ dependencies = [ [[package]] name = "wasmtime-asm-macros" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "86b9d329c718b3a18412a6a017c912b539baa8fe1210d21b651f6b4dbafed743" +checksum = "86292d6a9bf30c669582a40c4a4b8e0b8640e951f3635ee8e0acf7f87809961e" dependencies = [ "cfg-if", ] [[package]] name = "wasmtime-cache" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6fb4fc2bbf9c790a57875eba65588fa97acf57a7d784dc86d057e648d9a1ed91" +checksum = "8a180017db1233c902b992fea9484640d265f2fedf03db60eed57894cb2effcc" dependencies = [ "anyhow", "base64", @@ -2052,9 +2046,9 @@ dependencies = [ [[package]] name = "wasmtime-component-macro" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8d55ddfd02898885c39638eae9631cd430c83a368f5996ed0f7bfb181d02157" +checksum = "dc6aca484581f9651886dca45f9dea893e105713b58623d14b06c56d8fe3f3f1" dependencies = [ "anyhow", "proc-macro2", @@ -2067,15 +2061,15 @@ dependencies = [ [[package]] name = "wasmtime-component-util" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d6d69c430cddc70ec42159506962c66983ce0192ebde4eb125b7aabc49cff88" +checksum = "0aa907cc97ad039c43f98525d772f4841c2ce69a0c11eeec2a3a9c77fc730e87" [[package]] name = "wasmtime-cranelift" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31ca62f519225492bd555d0ec85a2dacb0c10315db3418c8b9aeb3824bf54a24" +checksum = "b57d58e220ae223855c5d030ef20753377bc716d0c81b34c1fe74c9f44268774" dependencies = [ "anyhow", "cfg-if", @@ -2098,9 +2092,9 @@ dependencies = [ [[package]] name = "wasmtime-cranelift-shared" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd5f2071f42e61490bf7cb95b9acdbe6a29dd577a398019304a960585f28b844" +checksum = "1ba2cfdfdbde42f0f3baeddb62f3555524dee9f836c96da8d466e299f75f5eee" dependencies = [ "anyhow", "cranelift-codegen", @@ -2114,9 +2108,9 @@ dependencies = [ [[package]] name = "wasmtime-environ" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82bf1a47f384610da19f58b0fd392ca6a3b720974315c08afb0392c0f3951fed" +checksum = "abbf3075d9ee7eb1263dc67949aced64d0f0bf27be8098d34d8e5826cf0ff0f2" dependencies = [ "anyhow", "bincode", @@ -2140,9 +2134,9 @@ dependencies = [ [[package]] name = "wasmtime-fiber" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0e31aecada2831e067ebfe93faa3001cc153d506f8af40bbea58aa1d20fe4820" +checksum = "3174f71c8fbd9d2cb1233ad9f912f106bdd2a1a6d11a1b7707974ba3ad5f304a" dependencies = [ "anyhow", "cc", @@ -2155,9 +2149,9 @@ dependencies = [ [[package]] name = "wasmtime-jit-debug" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "833dae95bc7a4f9177bf93f9497419763535b74e37eb8c37be53937d3281e287" +checksum = "4b0462a46b80d2352ee553b17d626b6468e9cec2220cc58ac31754fd7b58245e" dependencies = [ "object", "once_cell", @@ -2167,9 +2161,9 @@ dependencies = [ [[package]] name = "wasmtime-jit-icache-coherence" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "33f4121cb29dda08139b2824a734dd095d83ce843f2d613a84eb580b9cfc17ac" +checksum = "dacd2aa30fb20fd8cd0eb4e664024a1ab28a02958529fa05bf52117532a098fc" dependencies = [ "cfg-if", "libc", @@ -2178,9 +2172,9 @@ dependencies = [ [[package]] name = "wasmtime-runtime" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e517f2b996bb3b0e34a82a2bce194f850d9bcfc25c08328ef5fb71b071066b8" +checksum = "d14e97c4bb36d91bcdd194745446d595e67ce8b89916806270fdbee640c747fd" dependencies = [ "anyhow", "cc", @@ -2208,9 +2202,9 @@ dependencies = [ [[package]] name = "wasmtime-types" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "54a327d7a0ef57bd52a507d28b4561a74126c7a8535a2fc6f2025716bc6a52e8" +checksum = "530b94c627a454d24f520173d3145112d1b807c44c82697a57e1d8e28390cde4" dependencies = [ "cranelift-entity", "serde", @@ -2221,9 +2215,9 @@ dependencies = [ [[package]] name = "wasmtime-versioned-export-macros" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ef32eea9fc7035a55159a679d1e89b43ece5ae45d24eed4808e6a92c99a0da4" +checksum = "5399c175ddba4a471b9da45105dea3493059d52b2d54860eadb0df04c813948d" dependencies = [ "proc-macro2", "quote", @@ -2232,13 +2226,13 @@ dependencies = [ [[package]] name = "wasmtime-wasi" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d04d2fb2257245aa05ff799ded40520ae4d8cd31b0d14972afac89061f12fe12" +checksum = "aa0c9371a5270bc5e043f4eff80c572bc35585ab68d0a218d0ec3d3225085347" dependencies = [ "anyhow", "async-trait", - "bitflags 2.4.1", + "bitflags", "bytes", "cap-fs-ext", "cap-net-ext", @@ -2265,9 +2259,9 @@ dependencies = [ [[package]] name = "wasmtime-winch" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db3378c0e808a744b5d4df2a9a9d2746a53b151811926731f04fc401707f7d54" +checksum = "729dff119cfd2e2333504b52db6661e49278314c83276a01d15a2a86e566e614" dependencies = [ "anyhow", "cranelift-codegen", @@ -2282,21 +2276,21 @@ dependencies = [ [[package]] name = "wasmtime-wit-bindgen" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca677c36869e45602617b25a9968ec0d895ad9a0aee3756d9dee1ddd89456f91" +checksum = "6945fc6cfee04ba81016e9723bea77a2b913108e03904a4d901daedf208365f5" dependencies = [ "anyhow", - "heck", + "heck 0.4.1", "indexmap", "wit-parser 0.13.2", ] [[package]] name = "wasmtime-wmemcheck" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f4cbfb052d66f03603a9b77f18171ea245c7805714caad370a549a6344bf86b" +checksum = "e1711f429111e782fac0537e0b3eb2ab6f821613cf1ec3013f2a0ff3fde41745" [[package]] name = "wast" @@ -2309,24 +2303,24 @@ dependencies = [ [[package]] name = "wast" -version = "201.0.0" +version = "205.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ef6e1ef34d7da3e2b374fd2b1a9c0227aff6cad596e1b24df9b58d0f6222faa" +checksum = "441a6a195b3b5245e26d450bbcc91366c6b652382a22f63cbe3c73240e13b2bb" dependencies = [ "bumpalo", "leb128", "memchr", "unicode-width", - "wasm-encoder 0.201.0", + "wasm-encoder 0.205.0", ] [[package]] name = "wat" -version = "1.201.0" +version = "1.205.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "453d5b37a45b98dee4f4cb68015fc73634d7883bbef1c65e6e9c78d454cf3f32" +checksum = "19832624d606e7c6bf3cd4caa73578ecec5eac30c768269256d19c79900beb18" dependencies = [ - "wast 201.0.0", + "wast 205.0.0", ] [[package]] @@ -2354,13 +2348,13 @@ dependencies = [ [[package]] name = "wiggle" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b69812e493f8a43d8551abfaaf9539e1aff0cf56a58cdd276845fc4af035d0cd" +checksum = "186f82e079c09d2b7215ecaeacc97cac09631522016ba500ccc788749e882439" dependencies = [ "anyhow", "async-trait", - "bitflags 2.4.1", + "bitflags", "thiserror", "tracing", "wasmtime", @@ -2369,12 +2363,12 @@ dependencies = [ [[package]] name = "wiggle-generate" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0446357a5a7af0172848b6eca7b2aa1ab7d90065cd2ab02b633a322e1a52f636" +checksum = "def372d639555c826c4f287a7bdde673da127ecb95a3cd5453d53d8f3c0c07e4" dependencies = [ "anyhow", - "heck", + "heck 0.4.1", "proc-macro2", "quote", "shellexpand", @@ -2384,9 +2378,9 @@ dependencies = [ [[package]] name = "wiggle-macro" -version = "18.0.2" +version = "18.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9498ef53a12cf25dc6de9baef6ccd8b58d159202c412a19f4d72b218393086c5" +checksum = "93e43fc332703d1ec3aa86a5ce8bb49e6b95b6c617b90e726d3e70a0f70f48a5" dependencies = [ "proc-macro2", "quote", @@ -2418,9 +2412,9 @@ checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" [[package]] name = "winch-codegen" -version = "0.16.2" +version = "0.16.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8197ed4a2ebf612f0624ddda10de71f8cd2d3a4ecf8ffac0586a264599708d63" +checksum = "433cafb378ad01cd839974846204f56257ec34fc9d7db309ce1e34f24923fa6a" dependencies = [ "anyhow", "cranelift-codegen", @@ -2438,7 +2432,7 @@ version = "0.52.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "33ab640c8d7e35bf8ba19b884ba838ceb4fba93a4e8c65a9059d08afcfc683d9" dependencies = [ - "windows-targets 0.52.0", + "windows-targets 0.52.5", ] [[package]] @@ -2456,7 +2450,7 @@ version = "0.52.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" dependencies = [ - "windows-targets 0.52.0", + "windows-targets 0.52.5", ] [[package]] @@ -2476,17 +2470,18 @@ dependencies = [ [[package]] name = "windows-targets" -version = "0.52.0" +version = "0.52.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a18201040b24831fbb9e4eb208f8892e1f50a37feb53cc7ff887feb8f50e7cd" +checksum = "6f0713a46559409d202e70e28227288446bf7841d3211583a4b53e3f6d96e7eb" dependencies = [ - "windows_aarch64_gnullvm 0.52.0", - "windows_aarch64_msvc 0.52.0", - "windows_i686_gnu 0.52.0", - "windows_i686_msvc 0.52.0", - "windows_x86_64_gnu 0.52.0", - "windows_x86_64_gnullvm 0.52.0", - "windows_x86_64_msvc 0.52.0", + "windows_aarch64_gnullvm 0.52.5", + "windows_aarch64_msvc 0.52.5", + "windows_i686_gnu 0.52.5", + "windows_i686_gnullvm", + "windows_i686_msvc 0.52.5", + "windows_x86_64_gnu 0.52.5", + "windows_x86_64_gnullvm 0.52.5", + "windows_x86_64_msvc 0.52.5", ] [[package]] @@ -2497,9 +2492,9 @@ checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" [[package]] name = "windows_aarch64_gnullvm" -version = "0.52.0" +version = "0.52.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb7764e35d4db8a7921e09562a0304bf2f93e0a51bfccee0bd0bb0b666b015ea" +checksum = "7088eed71e8b8dda258ecc8bac5fb1153c5cffaf2578fc8ff5d61e23578d3263" [[package]] name = "windows_aarch64_msvc" @@ -2509,9 +2504,9 @@ checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" [[package]] name = "windows_aarch64_msvc" -version = "0.52.0" +version = "0.52.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbaa0368d4f1d2aaefc55b6fcfee13f41544ddf36801e793edbbfd7d7df075ef" +checksum = "9985fd1504e250c615ca5f281c3f7a6da76213ebd5ccc9561496568a2752afb6" [[package]] name = "windows_i686_gnu" @@ -2521,9 +2516,15 @@ checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" [[package]] name = "windows_i686_gnu" -version = "0.52.0" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "88ba073cf16d5372720ec942a8ccbf61626074c6d4dd2e745299726ce8b89670" + +[[package]] +name = "windows_i686_gnullvm" +version = "0.52.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a28637cb1fa3560a16915793afb20081aba2c92ee8af57b4d5f28e4b3e7df313" +checksum = "87f4261229030a858f36b459e748ae97545d6f1ec60e5e0d6a3d32e0dc232ee9" [[package]] name = "windows_i686_msvc" @@ -2533,9 +2534,9 @@ checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" [[package]] name = "windows_i686_msvc" -version = "0.52.0" +version = "0.52.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffe5e8e31046ce6230cc7215707b816e339ff4d4d67c65dffa206fd0f7aa7b9a" +checksum = "db3c2bf3d13d5b658be73463284eaf12830ac9a26a90c717b7f771dfe97487bf" [[package]] name = "windows_x86_64_gnu" @@ -2545,9 +2546,9 @@ checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" [[package]] name = "windows_x86_64_gnu" -version = "0.52.0" +version = "0.52.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d6fa32db2bc4a2f5abeacf2b69f7992cd09dca97498da74a151a3132c26befd" +checksum = "4e4246f76bdeff09eb48875a0fd3e2af6aada79d409d33011886d3e1581517d9" [[package]] name = "windows_x86_64_gnullvm" @@ -2557,9 +2558,9 @@ checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" [[package]] name = "windows_x86_64_gnullvm" -version = "0.52.0" +version = "0.52.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a657e1e9d3f514745a572a6846d3c7aa7dbe1658c056ed9c3344c4109a6949e" +checksum = "852298e482cd67c356ddd9570386e2862b5673c85bd5f88df9ab6802b334c596" [[package]] name = "windows_x86_64_msvc" @@ -2569,9 +2570,9 @@ checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" [[package]] name = "windows_x86_64_msvc" -version = "0.52.0" +version = "0.52.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dff9641d1cd4be8d1a070daf9e3773c5f67e78b4d9d42263020c057706765c04" +checksum = "bec47e5bfd1bff0eeaf6d8b485cc1074891a197ab4225d504cb7a1ab88b02bf0" [[package]] name = "winx" @@ -2579,7 +2580,7 @@ version = "0.36.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f9643b83820c0cd246ecabe5fa454dd04ba4fa67996369466d0747472d337346" dependencies = [ - "bitflags 2.4.1", + "bitflags", "windows-sys 0.52.0", ] @@ -2590,7 +2591,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "421c0c848a0660a8c22e2fd217929a0191f14476b68962afd2af89fd22e39825" dependencies = [ "anyhow", - "bitflags 2.4.1", + "bitflags", "indexmap", "log", "serde", @@ -2690,9 +2691,9 @@ dependencies = [ [[package]] name = "zstd-sys" -version = "2.0.9+zstd.1.5.5" +version = "2.0.10+zstd.1.5.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e16efa8a874a0481a574084d34cc26fdb3b99627480f785888deb6386506656" +checksum = "c253a4914af5bafc8fa8c86ee400827e83cf6ec01195ec1f1ed8441bf00d65aa" dependencies = [ "cc", "pkg-config", From 6db83d1ab3fb32cd259cd9312279c6102b99e83d Mon Sep 17 00:00:00 2001 From: Frank Rehwinkel Date: Mon, 22 Apr 2024 11:01:57 -0400 Subject: [PATCH 03/20] Cargo.toml dependencies: remove tokio feature from wasmtime-wasi --- Cargo.lock | 1 - Cargo.toml | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index b9f3726..089f243 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1813,7 +1813,6 @@ dependencies = [ "rustix", "system-interface", "thiserror", - "tokio", "tracing", "wasmtime", "wiggle", diff --git a/Cargo.toml b/Cargo.toml index 9913cce..310757b 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -22,7 +22,7 @@ rustyline = "13.0.0" tokio = { version = "1.36.0", features = ["macros"] } wasmtime = { version = "18.0.1", features = ["component-model"] } -wasmtime-wasi = { version = "18.0.2", features = ["tokio"] } +wasmtime-wasi = { version = "18.0.2" } wit-component = "0.201.0" wit-parser = "0.201.0" wasm-compose = "0.201.0" From 7ac7a641de3a8992aedbf4bc6a9b141d654fc31a Mon Sep 17 00:00:00 2001 From: Frank Rehwinkel Date: Mon, 22 Apr 2024 11:04:50 -0400 Subject: [PATCH 04/20] Cargo.toml dependencies: change rustyline from 13 to 14 --- Cargo.lock | 17 ++++++++++++----- Cargo.toml | 2 +- 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 089f243..cc15257 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -302,6 +302,12 @@ version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" +[[package]] +name = "cfg_aliases" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fd16c4719339c4530435d38e511904438d07cce7950afa3718a84ac36c10e89e" + [[package]] name = "clap" version = "4.5.4" @@ -1134,12 +1140,13 @@ dependencies = [ [[package]] name = "nix" -version = "0.27.1" +version = "0.28.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2eb04e9c688eff1c89d72b407f168cf79bb9e867a9d3323ed6c01519eb9cc053" +checksum = "ab2156c4fce2f8df6c499cc1c763e4394b7482525bf2a9701c9d79d215f519e4" dependencies = [ "bitflags", "cfg-if", + "cfg_aliases", "libc", ] @@ -1416,9 +1423,9 @@ dependencies = [ [[package]] name = "rustyline" -version = "13.0.0" +version = "14.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02a2d683a4ac90aeef5b1013933f6d977bd37d51ff3f4dad829d4931a7e6be86" +checksum = "7803e8936da37efd9b6d4478277f4b2b9bb5cdb37a113e8d63222e58da647e63" dependencies = [ "bitflags", "cfg-if", @@ -1433,7 +1440,7 @@ dependencies = [ "unicode-segmentation", "unicode-width", "utf8parse", - "winapi", + "windows-sys 0.52.0", ] [[package]] diff --git a/Cargo.toml b/Cargo.toml index 310757b..e86c731 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -18,7 +18,7 @@ home = "0.5.9" log = "0.4" nom = "7.1.3" nom_locate = "4.2" -rustyline = "13.0.0" +rustyline = "14.0.0" tokio = { version = "1.36.0", features = ["macros"] } wasmtime = { version = "18.0.1", features = ["component-model"] } From 79a31253840214c397b3e1df0fd22eb94b54e1a5 Mon Sep 17 00:00:00 2001 From: Frank Rehwinkel Date: Mon, 22 Apr 2024 11:10:47 -0400 Subject: [PATCH 05/20] Cargo.toml dependencies: change wasmtime from 18 to 19.0.2 --- Cargo.lock | 337 +++++++++++++++++++++++-------------------------- Cargo.toml | 4 +- src/runtime.rs | 8 +- 3 files changed, 167 insertions(+), 182 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index cc15257..ecabfe5 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -210,9 +210,9 @@ checksum = "514de17de45fdb8dc022b1a7975556c53c86f9f0aa5f534b98977b171857c2c9" [[package]] name = "cap-fs-ext" -version = "2.0.1" +version = "3.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88e341d15ac1029aadce600be764a1a1edafe40e03cde23285bc1d261b3a4866" +checksum = "769f8cd02eb04d57f14e2e371ebb533f96817f9b2525d73a5c72b61ca7973747" dependencies = [ "cap-primitives", "cap-std", @@ -222,9 +222,9 @@ dependencies = [ [[package]] name = "cap-net-ext" -version = "2.0.1" +version = "3.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "434168fe6533055f0f4204039abe3ff6d7db338ef46872a5fa39e9d5ad5ab7a9" +checksum = "59ff6d3fb274292a9af283417e383afe6ded1fe66f6472d2c781216d3d80c218" dependencies = [ "cap-primitives", "cap-std", @@ -234,9 +234,9 @@ dependencies = [ [[package]] name = "cap-primitives" -version = "2.0.1" +version = "3.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe16767ed8eee6d3f1f00d6a7576b81c226ab917eb54b96e5f77a5216ef67abb" +checksum = "90a0b44fc796b1a84535a63753d50ba3972c4db55c7255c186f79140e63d56d0" dependencies = [ "ambient-authority", "fs-set-times", @@ -251,9 +251,9 @@ dependencies = [ [[package]] name = "cap-rand" -version = "2.0.1" +version = "3.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "20e5695565f0cd7106bc3c7170323597540e772bb73e0be2cd2c662a0f8fa4ca" +checksum = "4327f08daac33a99bb03c54ae18c8f32c3ba31c728a33ddf683c6c6a5043de68" dependencies = [ "ambient-authority", "rand", @@ -261,9 +261,9 @@ dependencies = [ [[package]] name = "cap-std" -version = "2.0.1" +version = "3.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "593db20e4c51f62d3284bae7ee718849c3214f93a3b94ea1899ad85ba119d330" +checksum = "266626ce180cf9709f317d0bf9754e3a5006359d87f4bf792f06c9c5f1b63c0f" dependencies = [ "cap-primitives", "io-extras", @@ -273,9 +273,9 @@ dependencies = [ [[package]] name = "cap-time-ext" -version = "2.0.1" +version = "3.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "03261630f291f425430a36f38c847828265bc928f517cdd2004c56f4b02f002b" +checksum = "e1353421ba83c19da60726e35db0a89abef984b3be183ff6f58c5b8084fcd0c5" dependencies = [ "ambient-authority", "cap-primitives", @@ -381,9 +381,9 @@ checksum = "06ea2b9bc92be3c2baa9334a323ebca2d6f074ff852cd1d7b11064035cd3868f" [[package]] name = "cpp_demangle" -version = "0.3.5" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eeaa953eaad386a53111e47172c2fedba671e5684c8dd601a5f474f4f118710f" +checksum = "7e8227005286ec39567949b33df9896bcadfa6051bccca2488129f108ca23119" dependencies = [ "cfg-if", ] @@ -399,18 +399,18 @@ dependencies = [ [[package]] name = "cranelift-bforest" -version = "0.105.4" +version = "0.106.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "496c993b62bdfbe9b4c518b8b3e1fdba9f89ef89fcccc050ab61d91dfba9fbaf" +checksum = "3b57d4f3ffc28bbd6ef1ca7b50b20126717232f97487efe027d135d9d87eb29c" dependencies = [ "cranelift-entity", ] [[package]] name = "cranelift-codegen" -version = "0.105.4" +version = "0.106.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96b922abb6be41fc383f5e9da65b58d32d0d0a32c87dfe3bbbcb61a09119506c" +checksum = "d1f7d0ac7fd53f2c29db3ff9a063f6ff5a8be2abaa8f6942aceb6e1521e70df7" dependencies = [ "bumpalo", "cranelift-bforest", @@ -429,33 +429,33 @@ dependencies = [ [[package]] name = "cranelift-codegen-meta" -version = "0.105.4" +version = "0.106.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "634c2ed9ef8a04ca42535a3e2e7917e4b551f2f306f4df2d935a6e71e346c167" +checksum = "b40bf21460a600178956cb7fd900a7408c6587fbb988a8063f7215361801a1da" dependencies = [ "cranelift-codegen-shared", ] [[package]] name = "cranelift-codegen-shared" -version = "0.105.4" +version = "0.106.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00cde1425b4da28bb0d5ff010030ea9cc9be7aded342ae099b394284f17cefce" +checksum = "d792ecc1243b7ebec4a7f77d9ed428ef27456eeb1f8c780587a6f5c38841be19" [[package]] name = "cranelift-control" -version = "0.105.4" +version = "0.106.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1622125c99f1864aaf44e57971770c4a918d081d4b4af0bb597bdf624660ed66" +checksum = "cea2808043df964b73ad7582e09afbbe06a31f3fb9db834d53e74b4e16facaeb" dependencies = [ "arbitrary", ] [[package]] name = "cranelift-entity" -version = "0.105.4" +version = "0.106.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea97887aca1c0cbe7f8513874dc3603e9744fb1cfa78840ca8897bd2766bd35b" +checksum = "f1930946836da6f514da87625cd1a0331f3908e0de454628c24a0b97b130c4d4" dependencies = [ "serde", "serde_derive", @@ -463,9 +463,9 @@ dependencies = [ [[package]] name = "cranelift-frontend" -version = "0.105.4" +version = "0.106.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4cdade4c14183fe41482071ed77d6a38cb95a17c7a0a05e629152e6292c4f8cb" +checksum = "5482a5fcdf98f2f31b21093643bdcfe9030866b8be6481117022e7f52baa0f2b" dependencies = [ "cranelift-codegen", "log", @@ -475,15 +475,15 @@ dependencies = [ [[package]] name = "cranelift-isle" -version = "0.105.4" +version = "0.106.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbbe4d3ad7bd4bf4a8d916c8460b441cf92417f5cdeacce4dd1d96eee70b18a2" +checksum = "6f6e1869b6053383bdb356900e42e33555b4c9ebee05699469b7c53cdafc82ea" [[package]] name = "cranelift-native" -version = "0.105.4" +version = "0.106.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c46be4ed1fc8f36df4e2a442b8c30a39d8c03c1868182978f4c04ba2c25c9d4f" +checksum = "a91446e8045f1c4bc164b7bba68e2419c623904580d4b730877a663c6da38964" dependencies = [ "cranelift-codegen", "libc", @@ -492,9 +492,9 @@ dependencies = [ [[package]] name = "cranelift-wasm" -version = "0.105.4" +version = "0.106.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1d4c4a785a7866da89d20df159e3c4f96a5f14feb83b1f5998cfd5fe2e74d06" +checksum = "f8b17979b862d3b0d52de6ae3294ffe4d86c36027b56ad0443a7c8c8f921d14f" dependencies = [ "cranelift-codegen", "cranelift-entity", @@ -502,7 +502,7 @@ dependencies = [ "itertools", "log", "smallvec", - "wasmparser 0.121.2", + "wasmparser", "wasmtime-types", ] @@ -973,9 +973,9 @@ checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" [[package]] name = "itertools" -version = "0.10.5" +version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0fd2260e829bddf4cb6ea802289de2f86d6a7a690192fbe91b3f46e0f2c8473" +checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569" dependencies = [ "either", ] @@ -1486,6 +1486,15 @@ dependencies = [ "serde", ] +[[package]] +name = "serde_spanned" +version = "0.6.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eb3622f419d1296904700073ea6cc23ad690adbd66f13ea683df73298736f0c1" +dependencies = [ + "serde", +] + [[package]] name = "serde_yaml" version = "0.9.34+deprecated" @@ -1591,9 +1600,9 @@ dependencies = [ [[package]] name = "system-interface" -version = "0.26.1" +version = "0.27.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0682e006dd35771e392a6623ac180999a9a854b1d4a6c12fb2e804941c2b1f58" +checksum = "b858526d22750088a9b3cf2e3c2aacebd5377f13adeec02860c30d09113010a6" dependencies = [ "bitflags", "cap-fs-ext", @@ -1676,11 +1685,36 @@ dependencies = [ [[package]] name = "toml" -version = "0.5.11" +version = "0.8.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4f7f0dd8d50a853a531c426359045b1998f04219d88799810762cd4ad314234" +checksum = "e9dd1545e8208b4a5af1aa9bbd0b4cf7e9ea08fabc5d0a5c67fcaafa17433aa3" dependencies = [ "serde", + "serde_spanned", + "toml_datetime", + "toml_edit", +] + +[[package]] +name = "toml_datetime" +version = "0.6.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3550f4e9685620ac18a50ed434eb3aec30db8ba93b0287467bca5826ea25baf1" +dependencies = [ + "serde", +] + +[[package]] +name = "toml_edit" +version = "0.22.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3328d4f68a705b2a4498da1d580585d39a6510f98318a2cec3018a7ec61ddef" +dependencies = [ + "indexmap", + "serde", + "serde_spanned", + "toml_datetime", + "winnow", ] [[package]] @@ -1800,32 +1834,6 @@ version = "0.11.0+wasi-snapshot-preview1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" -[[package]] -name = "wasi-common" -version = "18.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ce5d3e7e6f0fabe518a9bea9c803081544ef38d986f04d7f86737faed32d2ae" -dependencies = [ - "anyhow", - "bitflags", - "cap-fs-ext", - "cap-rand", - "cap-std", - "cap-time-ext", - "fs-set-times", - "io-extras", - "io-lifetimes", - "log", - "once_cell", - "rustix", - "system-interface", - "thiserror", - "tracing", - "wasmtime", - "wiggle", - "windows-sys 0.52.0", -] - [[package]] name = "wasm-bindgen" version = "0.2.92" @@ -1897,19 +1905,10 @@ dependencies = [ "serde_yaml", "smallvec", "wasm-encoder 0.201.0", - "wasmparser 0.201.0", + "wasmparser", "wat", ] -[[package]] -name = "wasm-encoder" -version = "0.41.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "972f97a5d8318f908dded23594188a90bcd09365986b1163e66d70170e5287ae" -dependencies = [ - "leb128", -] - [[package]] name = "wasm-encoder" version = "0.201.0" @@ -1917,7 +1916,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b9c7d2731df60006819b013f64ccc2019691deccf6e11a1804bc850cd6748f1a" dependencies = [ "leb128", - "wasmparser 0.201.0", + "wasmparser", ] [[package]] @@ -1942,18 +1941,7 @@ dependencies = [ "serde_json", "spdx", "wasm-encoder 0.201.0", - "wasmparser 0.201.0", -] - -[[package]] -name = "wasmparser" -version = "0.121.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9dbe55c8f9d0dbd25d9447a5a889ff90c0cc3feaa7395310d3d826b2c703eaab" -dependencies = [ - "bitflags", - "indexmap", - "semver", + "wasmparser", ] [[package]] @@ -1969,19 +1957,19 @@ dependencies = [ [[package]] name = "wasmprinter" -version = "0.2.80" +version = "0.201.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60e73986a6b7fdfedb7c5bf9e7eb71135486507c8fbc4c0c42cffcb6532988b7" +checksum = "a67e66da702706ba08729a78e3c0079085f6bfcb1a62e4799e97bbf728c2c265" dependencies = [ "anyhow", - "wasmparser 0.121.2", + "wasmparser", ] [[package]] name = "wasmtime" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "69472708b96ee90579a482bdbb908ce97e53a9e5ebbcab59cc29c3977bcab512" +checksum = "4e300c0e3f19dc9064e3b17ce661088646c70dbdde36aab46470ed68ba58db7d" dependencies = [ "addr2line", "anyhow", @@ -2001,12 +1989,13 @@ dependencies = [ "paste", "rayon", "rustix", + "semver", "serde", "serde_derive", "serde_json", "target-lexicon", - "wasm-encoder 0.41.2", - "wasmparser 0.121.2", + "wasm-encoder 0.201.0", + "wasmparser", "wasmtime-cache", "wasmtime-component-macro", "wasmtime-component-util", @@ -2016,6 +2005,7 @@ dependencies = [ "wasmtime-jit-debug", "wasmtime-jit-icache-coherence", "wasmtime-runtime", + "wasmtime-slab", "wasmtime-winch", "wat", "windows-sys 0.52.0", @@ -2023,18 +2013,18 @@ dependencies = [ [[package]] name = "wasmtime-asm-macros" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "86292d6a9bf30c669582a40c4a4b8e0b8640e951f3635ee8e0acf7f87809961e" +checksum = "110aa598e02a136fb095ca70fa96367fc16bab55256a131e66f9b58f16c73daf" dependencies = [ "cfg-if", ] [[package]] name = "wasmtime-cache" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a180017db1233c902b992fea9484640d265f2fedf03db60eed57894cb2effcc" +checksum = "c4e660537b0ac2fc76917fb0cc9d403d2448b6983a84e59c51f7fea7b7dae024" dependencies = [ "anyhow", "base64", @@ -2052,9 +2042,9 @@ dependencies = [ [[package]] name = "wasmtime-component-macro" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc6aca484581f9651886dca45f9dea893e105713b58623d14b06c56d8fe3f3f1" +checksum = "091f32ce586251ac4d07019388fb665b010d9518ffe47be1ddbabb162eed6007" dependencies = [ "anyhow", "proc-macro2", @@ -2062,20 +2052,20 @@ dependencies = [ "syn", "wasmtime-component-util", "wasmtime-wit-bindgen", - "wit-parser 0.13.2", + "wit-parser", ] [[package]] name = "wasmtime-component-util" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0aa907cc97ad039c43f98525d772f4841c2ce69a0c11eeec2a3a9c77fc730e87" +checksum = "0dd17dc1ebc0b28fd24b6b9d07638f55b82ae908918ff08fd221f8b0fefa9125" [[package]] name = "wasmtime-cranelift" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b57d58e220ae223855c5d030ef20753377bc716d0c81b34c1fe74c9f44268774" +checksum = "e923262451a4b5b39fe02f69f1338d56356db470e289ea1887346b9c7f592738" dependencies = [ "anyhow", "cfg-if", @@ -2090,7 +2080,7 @@ dependencies = [ "object", "target-lexicon", "thiserror", - "wasmparser 0.121.2", + "wasmparser", "wasmtime-cranelift-shared", "wasmtime-environ", "wasmtime-versioned-export-macros", @@ -2098,9 +2088,9 @@ dependencies = [ [[package]] name = "wasmtime-cranelift-shared" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ba2cfdfdbde42f0f3baeddb62f3555524dee9f836c96da8d466e299f75f5eee" +checksum = "508898cbbea0df81a5d29cfc1c7c72431a1bc4c9e89fd9514b4c868474c05c7a" dependencies = [ "anyhow", "cranelift-codegen", @@ -2114,9 +2104,9 @@ dependencies = [ [[package]] name = "wasmtime-environ" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abbf3075d9ee7eb1263dc67949aced64d0f0bf27be8098d34d8e5826cf0ff0f2" +checksum = "d7e3f2aa72dbb64c19708646e1ff97650f34e254598b82bad5578ea9c80edd30" dependencies = [ "anyhow", "bincode", @@ -2131,8 +2121,8 @@ dependencies = [ "serde_derive", "target-lexicon", "thiserror", - "wasm-encoder 0.41.2", - "wasmparser 0.121.2", + "wasm-encoder 0.201.0", + "wasmparser", "wasmprinter", "wasmtime-component-util", "wasmtime-types", @@ -2140,9 +2130,9 @@ dependencies = [ [[package]] name = "wasmtime-fiber" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3174f71c8fbd9d2cb1233ad9f912f106bdd2a1a6d11a1b7707974ba3ad5f304a" +checksum = "9235b643527bcbac808216ed342e1fba324c95f14a62762acfa6f2e6ca5edbd6" dependencies = [ "anyhow", "cc", @@ -2155,9 +2145,9 @@ dependencies = [ [[package]] name = "wasmtime-jit-debug" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b0462a46b80d2352ee553b17d626b6468e9cec2220cc58ac31754fd7b58245e" +checksum = "92de34217bf7f0464262adf391a9950eba440f9dfc7d3b0e3209302875c6f65f" dependencies = [ "object", "once_cell", @@ -2167,9 +2157,9 @@ dependencies = [ [[package]] name = "wasmtime-jit-icache-coherence" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dacd2aa30fb20fd8cd0eb4e664024a1ab28a02958529fa05bf52117532a098fc" +checksum = "c22ca2ef4d87b23d400660373453e274b2251bc2d674e3102497f690135e04b0" dependencies = [ "cfg-if", "libc", @@ -2178,9 +2168,9 @@ dependencies = [ [[package]] name = "wasmtime-runtime" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d14e97c4bb36d91bcdd194745446d595e67ce8b89916806270fdbee640c747fd" +checksum = "1806ee242ca4fd183309b7406e4e83ae7739b7569f395d56700de7c7ef9f5eb8" dependencies = [ "anyhow", "cc", @@ -2196,7 +2186,7 @@ dependencies = [ "psm", "rustix", "sptr", - "wasm-encoder 0.41.2", + "wasm-encoder 0.201.0", "wasmtime-asm-macros", "wasmtime-environ", "wasmtime-fiber", @@ -2206,24 +2196,30 @@ dependencies = [ "windows-sys 0.52.0", ] +[[package]] +name = "wasmtime-slab" +version = "19.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "20c58bef9ce877fd06acb58f08d003af17cb05cc51225b455e999fbad8e584c0" + [[package]] name = "wasmtime-types" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "530b94c627a454d24f520173d3145112d1b807c44c82697a57e1d8e28390cde4" +checksum = "cebe297aa063136d9d2e5b347c1528868aa43c2c8d0e1eb0eec144567e38fe0f" dependencies = [ "cranelift-entity", "serde", "serde_derive", "thiserror", - "wasmparser 0.121.2", + "wasmparser", ] [[package]] name = "wasmtime-versioned-export-macros" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5399c175ddba4a471b9da45105dea3493059d52b2d54860eadb0df04c813948d" +checksum = "ffaafa5c12355b1a9ee068e9295d50c4ca0a400c721950cdae4f5b54391a2da5" dependencies = [ "proc-macro2", "quote", @@ -2232,9 +2228,9 @@ dependencies = [ [[package]] name = "wasmtime-wasi" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa0c9371a5270bc5e043f4eff80c572bc35585ab68d0a218d0ec3d3225085347" +checksum = "b95961546319d4019625920756967a929879d1d46c4e5f89a74e9f4405655b0c" dependencies = [ "anyhow", "async-trait", @@ -2249,7 +2245,6 @@ dependencies = [ "futures", "io-extras", "io-lifetimes", - "log", "once_cell", "rustix", "system-interface", @@ -2257,7 +2252,6 @@ dependencies = [ "tokio", "tracing", "url", - "wasi-common", "wasmtime", "wiggle", "windows-sys 0.52.0", @@ -2265,16 +2259,16 @@ dependencies = [ [[package]] name = "wasmtime-winch" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "729dff119cfd2e2333504b52db6661e49278314c83276a01d15a2a86e566e614" +checksum = "d618b4e90d3f259b1b77411ce573c9f74aade561957102132e169918aabdc863" dependencies = [ "anyhow", "cranelift-codegen", "gimli", "object", "target-lexicon", - "wasmparser 0.121.2", + "wasmparser", "wasmtime-cranelift-shared", "wasmtime-environ", "winch-codegen", @@ -2282,21 +2276,21 @@ dependencies = [ [[package]] name = "wasmtime-wit-bindgen" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6945fc6cfee04ba81016e9723bea77a2b913108e03904a4d901daedf208365f5" +checksum = "7c7a253c8505edd7493603e548bff3af937b0b7dbf2b498bd5ff2131b651af72" dependencies = [ "anyhow", "heck 0.4.1", "indexmap", - "wit-parser 0.13.2", + "wit-parser", ] [[package]] name = "wasmtime-wmemcheck" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1711f429111e782fac0537e0b3eb2ab6f821613cf1ec3013f2a0ff3fde41745" +checksum = "c9a8c62e9df8322b2166d2a6f096fbec195ddb093748fd74170dcf25ef596769" [[package]] name = "wast" @@ -2349,14 +2343,14 @@ dependencies = [ "wasmtime", "wasmtime-wasi", "wit-component", - "wit-parser 0.201.0", + "wit-parser", ] [[package]] name = "wiggle" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "186f82e079c09d2b7215ecaeacc97cac09631522016ba500ccc788749e882439" +checksum = "899d3fe5fbacd02f114cacdaa1cca9040280c4153c71833a77b9609c60ccf72b" dependencies = [ "anyhow", "async-trait", @@ -2369,9 +2363,9 @@ dependencies = [ [[package]] name = "wiggle-generate" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "def372d639555c826c4f287a7bdde673da127ecb95a3cd5453d53d8f3c0c07e4" +checksum = "2df5887f452cff44ffe1e1aba69b7fafe812deed38498446fa7a46b55e962cd5" dependencies = [ "anyhow", "heck 0.4.1", @@ -2384,9 +2378,9 @@ dependencies = [ [[package]] name = "wiggle-macro" -version = "18.0.4" +version = "19.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93e43fc332703d1ec3aa86a5ce8bb49e6b95b6c617b90e726d3e70a0f70f48a5" +checksum = "acdb12de36507498abaa3a042f895a43ee00a2f6125b6901b9a27edf72bfdbe7" dependencies = [ "proc-macro2", "quote", @@ -2418,9 +2412,9 @@ checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" [[package]] name = "winch-codegen" -version = "0.16.4" +version = "0.17.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "433cafb378ad01cd839974846204f56257ec34fc9d7db309ce1e34f24923fa6a" +checksum = "2d15869abc9e3bb29c017c003dbe007a08e9910e8ff9023a962aa13c1b2ee6af" dependencies = [ "anyhow", "cranelift-codegen", @@ -2428,7 +2422,7 @@ dependencies = [ "regalloc2", "smallvec", "target-lexicon", - "wasmparser 0.121.2", + "wasmparser", "wasmtime-environ", ] @@ -2580,6 +2574,15 @@ version = "0.52.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bec47e5bfd1bff0eeaf6d8b485cc1074891a197ab4225d504cb7a1ab88b02bf0" +[[package]] +name = "winnow" +version = "0.6.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0c976aaaa0e1f90dbb21e9587cdaf1d9679a1cde8875c0d6bd83ab96a208352" +dependencies = [ + "memchr", +] + [[package]] name = "winx" version = "0.36.3" @@ -2605,25 +2608,8 @@ dependencies = [ "serde_json", "wasm-encoder 0.201.0", "wasm-metadata", - "wasmparser 0.201.0", - "wit-parser 0.201.0", -] - -[[package]] -name = "wit-parser" -version = "0.13.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "316b36a9f0005f5aa4b03c39bc3728d045df136f8c13a73b7db4510dec725e08" -dependencies = [ - "anyhow", - "id-arena", - "indexmap", - "log", - "semver", - "serde", - "serde_derive", - "serde_json", - "unicode-xid", + "wasmparser", + "wit-parser", ] [[package]] @@ -2641,7 +2627,7 @@ dependencies = [ "serde_derive", "serde_json", "unicode-xid", - "wasmparser 0.201.0", + "wasmparser", ] [[package]] @@ -2678,20 +2664,19 @@ dependencies = [ [[package]] name = "zstd" -version = "0.11.2+zstd.1.5.2" +version = "0.13.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "20cc960326ece64f010d2d2107537f26dc589a6573a316bd5b1dba685fa5fde4" +checksum = "2d789b1514203a1120ad2429eae43a7bd32b90976a7bb8a05f7ec02fa88cc23a" dependencies = [ "zstd-safe", ] [[package]] name = "zstd-safe" -version = "5.0.2+zstd.1.5.2" +version = "7.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d2a5585e04f9eea4b2a3d1eca508c4dee9592a89ef6f450c11719da0726f4db" +checksum = "1cd99b45c6bc03a018c8b8a86025678c87e55526064e38f9df301989dce7ec0a" dependencies = [ - "libc", "zstd-sys", ] diff --git a/Cargo.toml b/Cargo.toml index e86c731..84b1e98 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -21,8 +21,8 @@ nom_locate = "4.2" rustyline = "14.0.0" tokio = { version = "1.36.0", features = ["macros"] } -wasmtime = { version = "18.0.1", features = ["component-model"] } -wasmtime-wasi = { version = "18.0.2" } +wasmtime = { version = "19.0.2", features = ["component-model"] } +wasmtime-wasi = { version = "19.0.2" } wit-component = "0.201.0" wit-parser = "0.201.0" wasm-compose = "0.201.0" diff --git a/src/runtime.rs b/src/runtime.rs index b870bae..32e295a 100644 --- a/src/runtime.rs +++ b/src/runtime.rs @@ -9,7 +9,7 @@ use wasmtime::{ component::{Component, Func, Instance, Linker, ResourceTable, Val}, Config, Engine, Store, }; -use wasmtime_wasi::preview2::{ +use wasmtime_wasi::{ HostOutputStream, Stdout, StdoutStream, StreamResult, Subscribe, WasiCtx, WasiCtxBuilder, WasiView, }; @@ -42,7 +42,7 @@ impl Runtime { let imports_wasi_cli = resolver.imports_wasi_cli(); if imports_wasi_cli { log::debug!("Linking with wasi"); - wasmtime_wasi::preview2::command::sync::add_to_linker(&mut linker)?; + wasmtime_wasi::command::sync::add_to_linker(&mut linker)?; } for (import_name, import) in resolver.imports(!imports_wasi_cli) { let import_name = resolver.world_item_name(import_name); @@ -167,7 +167,7 @@ impl Runtime { ) -> anyhow::Result<()> { let component = load_component(&self.engine, component_bytes)?; let mut linker = Linker::::new(&self.engine); - wasmtime_wasi::preview2::command::sync::add_to_linker(&mut linker)?; + wasmtime_wasi::command::sync::add_to_linker(&mut linker)?; let mut root = self.linker.root(); let mut import_instance = root .instance(&import_ident.to_string()) @@ -277,7 +277,7 @@ impl Runtime { let component = load_component(&self.engine, component_bytes)?; let mut linker = Linker::::new(&self.engine); - wasmtime_wasi::preview2::command::sync::add_to_linker(&mut linker)?; + wasmtime_wasi::command::sync::add_to_linker(&mut linker)?; let export_func = { let mut store_lock = self.import_impls.store.lock().unwrap(); let export_instance = linker.instantiate(&mut *store_lock, &component)?; From 3fb65d82cf0ca168c69e27a014c9d1f364302443 Mon Sep 17 00:00:00 2001 From: Frank Rehwinkel Date: Mon, 22 Apr 2024 11:16:17 -0400 Subject: [PATCH 06/20] Cargo.toml dependencies: change wit parts from 0.201.0 to 0.205.0 --- Cargo.lock | 81 ++++++++++++++++++++++++++++++++++++------------------ Cargo.toml | 6 ++-- src/wit.rs | 4 +-- 3 files changed, 60 insertions(+), 31 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index ecabfe5..171de60 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -502,7 +502,7 @@ dependencies = [ "itertools", "log", "smallvec", - "wasmparser", + "wasmparser 0.201.0", "wasmtime-types", ] @@ -1890,9 +1890,9 @@ checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" [[package]] name = "wasm-compose" -version = "0.201.0" +version = "0.205.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "10501f9526fedb9592271a19c34257582b6abcb4636e276ee75cb95aa242ee2a" +checksum = "1c2e7f958c36da29d15661a855d0162b2361de5896c9bfa98976b61b0f75c597" dependencies = [ "anyhow", "heck 0.4.1", @@ -1904,8 +1904,8 @@ dependencies = [ "serde_derive", "serde_yaml", "smallvec", - "wasm-encoder 0.201.0", - "wasmparser", + "wasm-encoder 0.205.0", + "wasmparser 0.205.0", "wat", ] @@ -1916,7 +1916,6 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b9c7d2731df60006819b013f64ccc2019691deccf6e11a1804bc850cd6748f1a" dependencies = [ "leb128", - "wasmparser", ] [[package]] @@ -1926,13 +1925,14 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "90e95b3563d164f33c1cfb0a7efbd5940c37710019be10cd09f800fdec8b0e5c" dependencies = [ "leb128", + "wasmparser 0.205.0", ] [[package]] name = "wasm-metadata" -version = "0.201.0" +version = "0.205.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fd83062c17b9f4985d438603cde0a5e8c5c8198201a6937f778b607924c7da2" +checksum = "e9855ad6dd4d099fa8505f01fb0b84c7e3efd5f555207329e3ad938d5f394fe7" dependencies = [ "anyhow", "indexmap", @@ -1940,8 +1940,8 @@ dependencies = [ "serde_derive", "serde_json", "spdx", - "wasm-encoder 0.201.0", - "wasmparser", + "wasm-encoder 0.205.0", + "wasmparser 0.205.0", ] [[package]] @@ -1955,6 +1955,17 @@ dependencies = [ "semver", ] +[[package]] +name = "wasmparser" +version = "0.205.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1d457bb52804242e09d55a306e53ddbc65d1d29ed83db6a4eea3ed412ee0cfdf" +dependencies = [ + "bitflags", + "indexmap", + "semver", +] + [[package]] name = "wasmprinter" version = "0.201.0" @@ -1962,7 +1973,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a67e66da702706ba08729a78e3c0079085f6bfcb1a62e4799e97bbf728c2c265" dependencies = [ "anyhow", - "wasmparser", + "wasmparser 0.201.0", ] [[package]] @@ -1995,7 +2006,7 @@ dependencies = [ "serde_json", "target-lexicon", "wasm-encoder 0.201.0", - "wasmparser", + "wasmparser 0.201.0", "wasmtime-cache", "wasmtime-component-macro", "wasmtime-component-util", @@ -2052,7 +2063,7 @@ dependencies = [ "syn", "wasmtime-component-util", "wasmtime-wit-bindgen", - "wit-parser", + "wit-parser 0.201.0", ] [[package]] @@ -2080,7 +2091,7 @@ dependencies = [ "object", "target-lexicon", "thiserror", - "wasmparser", + "wasmparser 0.201.0", "wasmtime-cranelift-shared", "wasmtime-environ", "wasmtime-versioned-export-macros", @@ -2122,7 +2133,7 @@ dependencies = [ "target-lexicon", "thiserror", "wasm-encoder 0.201.0", - "wasmparser", + "wasmparser 0.201.0", "wasmprinter", "wasmtime-component-util", "wasmtime-types", @@ -2212,7 +2223,7 @@ dependencies = [ "serde", "serde_derive", "thiserror", - "wasmparser", + "wasmparser 0.201.0", ] [[package]] @@ -2268,7 +2279,7 @@ dependencies = [ "gimli", "object", "target-lexicon", - "wasmparser", + "wasmparser 0.201.0", "wasmtime-cranelift-shared", "wasmtime-environ", "winch-codegen", @@ -2283,7 +2294,7 @@ dependencies = [ "anyhow", "heck 0.4.1", "indexmap", - "wit-parser", + "wit-parser 0.201.0", ] [[package]] @@ -2343,7 +2354,7 @@ dependencies = [ "wasmtime", "wasmtime-wasi", "wit-component", - "wit-parser", + "wit-parser 0.205.0", ] [[package]] @@ -2422,7 +2433,7 @@ dependencies = [ "regalloc2", "smallvec", "target-lexicon", - "wasmparser", + "wasmparser 0.201.0", "wasmtime-environ", ] @@ -2595,9 +2606,9 @@ dependencies = [ [[package]] name = "wit-component" -version = "0.201.0" +version = "0.205.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "421c0c848a0660a8c22e2fd217929a0191f14476b68962afd2af89fd22e39825" +checksum = "74841e17b2c2bfbd8ca8c45190ef85dff1c5e8659f0e2d164802ffc87dfb18c3" dependencies = [ "anyhow", "bitflags", @@ -2606,10 +2617,10 @@ dependencies = [ "serde", "serde_derive", "serde_json", - "wasm-encoder 0.201.0", + "wasm-encoder 0.205.0", "wasm-metadata", - "wasmparser", - "wit-parser", + "wasmparser 0.205.0", + "wit-parser 0.205.0", ] [[package]] @@ -2627,7 +2638,25 @@ dependencies = [ "serde_derive", "serde_json", "unicode-xid", - "wasmparser", + "wasmparser 0.201.0", +] + +[[package]] +name = "wit-parser" +version = "0.205.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a3db34c7688c161ed7bd1b2f8055dca9fb2c15201db58754e9c48a0805f32e5f" +dependencies = [ + "anyhow", + "id-arena", + "indexmap", + "log", + "semver", + "serde", + "serde_derive", + "serde_json", + "unicode-xid", + "wasmparser 0.205.0", ] [[package]] diff --git a/Cargo.toml b/Cargo.toml index 84b1e98..7388af0 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -23,6 +23,6 @@ tokio = { version = "1.36.0", features = ["macros"] } wasmtime = { version = "19.0.2", features = ["component-model"] } wasmtime-wasi = { version = "19.0.2" } -wit-component = "0.201.0" -wit-parser = "0.201.0" -wasm-compose = "0.201.0" +wit-component = "0.205.0" +wit-parser = "0.205.0" +wasm-compose = "0.205.0" diff --git a/src/wit.rs b/src/wit.rs index 79b5b78..f6478b5 100644 --- a/src/wit.rs +++ b/src/wit.rs @@ -127,8 +127,8 @@ impl WorldResolver { wit_parser::Type::S16 => "s16", wit_parser::Type::S32 => "s32", wit_parser::Type::S64 => "s64", - wit_parser::Type::Float32 => "float32", - wit_parser::Type::Float64 => "float64", + wit_parser::Type::F32 => "f32", + wit_parser::Type::F64 => "f64", wit_parser::Type::String => "string", wit_parser::Type::Char => "char", wit_parser::Type::Id(id) => { From 1f5aba12ad886cd1c00352ab2e12221f34d17c03 Mon Sep 17 00:00:00 2001 From: Frank Rehwinkel Date: Thu, 25 Apr 2024 13:48:28 -0400 Subject: [PATCH 07/20] move to wasmtime 20 from 19 --- Cargo.lock | 229 ++++++++++++++++++++++------------------------- Cargo.toml | 4 +- src/command.rs | 10 +-- src/evaluator.rs | 54 ++++++----- src/runtime.rs | 14 ++- 5 files changed, 151 insertions(+), 160 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 171de60..ab997fd 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -141,7 +141,7 @@ dependencies = [ "cfg-if", "libc", "miniz_oxide", - "object", + "object 0.32.2", "rustc-demangle", ] @@ -399,18 +399,18 @@ dependencies = [ [[package]] name = "cranelift-bforest" -version = "0.106.2" +version = "0.107.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b57d4f3ffc28bbd6ef1ca7b50b20126717232f97487efe027d135d9d87eb29c" +checksum = "79b27922a6879b5b5361d0a084cb0b1941bf109a98540addcb932da13b68bed4" dependencies = [ "cranelift-entity", ] [[package]] name = "cranelift-codegen" -version = "0.106.2" +version = "0.107.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d1f7d0ac7fd53f2c29db3ff9a063f6ff5a8be2abaa8f6942aceb6e1521e70df7" +checksum = "304c455b28bf56372729acb356afbb55d622f2b0f2f7837aa5e57c138acaac4d" dependencies = [ "bumpalo", "cranelift-bforest", @@ -429,33 +429,33 @@ dependencies = [ [[package]] name = "cranelift-codegen-meta" -version = "0.106.2" +version = "0.107.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b40bf21460a600178956cb7fd900a7408c6587fbb988a8063f7215361801a1da" +checksum = "1653c56b99591d07f67c5ca7f9f25888948af3f4b97186bff838d687d666f613" dependencies = [ "cranelift-codegen-shared", ] [[package]] name = "cranelift-codegen-shared" -version = "0.106.2" +version = "0.107.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d792ecc1243b7ebec4a7f77d9ed428ef27456eeb1f8c780587a6f5c38841be19" +checksum = "f5b6a9cf6b6eb820ee3f973a0db313c05dc12d370f37b4fe9630286e1672573f" [[package]] name = "cranelift-control" -version = "0.106.2" +version = "0.107.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cea2808043df964b73ad7582e09afbbe06a31f3fb9db834d53e74b4e16facaeb" +checksum = "d9d06e6bf30075fb6bed9e034ec046475093392eea1aff90eb5c44c4a033d19a" dependencies = [ "arbitrary", ] [[package]] name = "cranelift-entity" -version = "0.106.2" +version = "0.107.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1930946836da6f514da87625cd1a0331f3908e0de454628c24a0b97b130c4d4" +checksum = "29be04f931b73cdb9694874a295027471817f26f26d2f0ebe5454153176b6e3a" dependencies = [ "serde", "serde_derive", @@ -463,9 +463,9 @@ dependencies = [ [[package]] name = "cranelift-frontend" -version = "0.106.2" +version = "0.107.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5482a5fcdf98f2f31b21093643bdcfe9030866b8be6481117022e7f52baa0f2b" +checksum = "a07fd7393041d7faa2f37426f5dc7fc04003b70988810e8c063beefeff1cd8f9" dependencies = [ "cranelift-codegen", "log", @@ -475,15 +475,15 @@ dependencies = [ [[package]] name = "cranelift-isle" -version = "0.106.2" +version = "0.107.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f6e1869b6053383bdb356900e42e33555b4c9ebee05699469b7c53cdafc82ea" +checksum = "f341d7938caa6dff8149dac05bb2b53fc680323826b83b4cf175ab9f5139a3c9" [[package]] name = "cranelift-native" -version = "0.106.2" +version = "0.107.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a91446e8045f1c4bc164b7bba68e2419c623904580d4b730877a663c6da38964" +checksum = "82af6066e6448d26eeabb7aa26a43f7ff79f8217b06bade4ee6ef230aecc8880" dependencies = [ "cranelift-codegen", "libc", @@ -492,9 +492,9 @@ dependencies = [ [[package]] name = "cranelift-wasm" -version = "0.106.2" +version = "0.107.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8b17979b862d3b0d52de6ae3294ffe4d86c36027b56ad0443a7c8c8f921d14f" +checksum = "2766fab7284a914a7f17f90ebe865c86453225fb8637ac31f123f5028fee69cd" dependencies = [ "cranelift-codegen", "cranelift-entity", @@ -502,7 +502,7 @@ dependencies = [ "itertools", "log", "smallvec", - "wasmparser 0.201.0", + "wasmparser 0.202.0", "wasmtime-types", ] @@ -1065,10 +1065,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "90ed8c1e510134f979dbc4f070f87d4313098b704861a105fe34231c70a3901c" [[package]] -name = "mach" -version = "0.3.2" +name = "mach2" +version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b823e83b2affd8f40a9ee8c29dbc56404c1e34cd2710921f2801e2cf29527afa" +checksum = "19b955cdeb2a02b9117f121ce63aa52d08ade45de53e48fe6a38b39c10f6f709" dependencies = [ "libc", ] @@ -1186,6 +1186,15 @@ name = "object" version = "0.32.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a6a622008b6e321afc04970976f62ee297fdbaa6f95318ca343e3eebb9648441" +dependencies = [ + "memchr", +] + +[[package]] +name = "object" +version = "0.33.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d8dd6c0cdf9429bce006e1362bfce61fa1bfd8c898a643ed8d2b471934701d3d" dependencies = [ "crc32fast", "hashbrown 0.14.3", @@ -1408,9 +1417,9 @@ checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2" [[package]] name = "rustix" -version = "0.38.33" +version = "0.38.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3cc72858054fcff6d7dea32df2aeaee6a7c24227366d7ea429aada2f26b16ad" +checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" dependencies = [ "bitflags", "errno", @@ -1911,9 +1920,9 @@ dependencies = [ [[package]] name = "wasm-encoder" -version = "0.201.0" +version = "0.202.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9c7d2731df60006819b013f64ccc2019691deccf6e11a1804bc850cd6748f1a" +checksum = "bfd106365a7f5f7aa3c1916a98cbb3ad477f5ff96ddb130285a91c6e7429e67a" dependencies = [ "leb128", ] @@ -1946,9 +1955,9 @@ dependencies = [ [[package]] name = "wasmparser" -version = "0.201.0" +version = "0.202.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84e5df6dba6c0d7fafc63a450f1738451ed7a0b52295d83e868218fa286bf708" +checksum = "d6998515d3cf3f8b980ef7c11b29a9b1017d4cf86b99ae93b546992df9931413" dependencies = [ "bitflags", "indexmap", @@ -1968,19 +1977,19 @@ dependencies = [ [[package]] name = "wasmprinter" -version = "0.201.0" +version = "0.202.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a67e66da702706ba08729a78e3c0079085f6bfcb1a62e4799e97bbf728c2c265" +checksum = "ab1cc9508685eef9502e787f4d4123745f5651a1e29aec047645d3cac1e2da7a" dependencies = [ "anyhow", - "wasmparser 0.201.0", + "wasmparser 0.202.0", ] [[package]] name = "wasmtime" -version = "19.0.2" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e300c0e3f19dc9064e3b17ce661088646c70dbdde36aab46470ed68ba58db7d" +checksum = "5a5990663c28d81015ddbb02a068ac1bf396a4ea296eba7125b2dfc7c00cb52e" dependencies = [ "addr2line", "anyhow", @@ -1995,7 +2004,7 @@ dependencies = [ "ittapi", "libc", "log", - "object", + "object 0.33.0", "once_cell", "paste", "rayon", @@ -2005,8 +2014,8 @@ dependencies = [ "serde_derive", "serde_json", "target-lexicon", - "wasm-encoder 0.201.0", - "wasmparser 0.201.0", + "wasm-encoder 0.202.0", + "wasmparser 0.202.0", "wasmtime-cache", "wasmtime-component-macro", "wasmtime-component-util", @@ -2024,18 +2033,18 @@ dependencies = [ [[package]] name = "wasmtime-asm-macros" -version = "19.0.2" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "110aa598e02a136fb095ca70fa96367fc16bab55256a131e66f9b58f16c73daf" +checksum = "625ee94c72004f3ea0228989c9506596e469517d7d0ed66f7300d1067bdf1ca9" dependencies = [ "cfg-if", ] [[package]] name = "wasmtime-cache" -version = "19.0.2" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4e660537b0ac2fc76917fb0cc9d403d2448b6983a84e59c51f7fea7b7dae024" +checksum = "98534bf28de232299e83eab33984a7a6c40c69534d6bd0ea216150b63d41a83a" dependencies = [ "anyhow", "base64", @@ -2053,9 +2062,9 @@ dependencies = [ [[package]] name = "wasmtime-component-macro" -version = "19.0.2" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "091f32ce586251ac4d07019388fb665b010d9518ffe47be1ddbabb162eed6007" +checksum = "64f84414a25ee3a624c8b77550f3fe7b5d8145bd3405ca58886ee6900abb6dc2" dependencies = [ "anyhow", "proc-macro2", @@ -2063,20 +2072,20 @@ dependencies = [ "syn", "wasmtime-component-util", "wasmtime-wit-bindgen", - "wit-parser 0.201.0", + "wit-parser 0.202.0", ] [[package]] name = "wasmtime-component-util" -version = "19.0.2" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0dd17dc1ebc0b28fd24b6b9d07638f55b82ae908918ff08fd221f8b0fefa9125" +checksum = "78580bdb4e04c7da3bf98088559ca1d29382668536e4d5c7f2f966d79c390307" [[package]] name = "wasmtime-cranelift" -version = "19.0.2" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e923262451a4b5b39fe02f69f1338d56356db470e289ea1887346b9c7f592738" +checksum = "b60df0ee08c6a536c765f69e9e8205273435b66d02dd401e938769a2622a6c1a" dependencies = [ "anyhow", "cfg-if", @@ -2088,36 +2097,19 @@ dependencies = [ "cranelift-wasm", "gimli", "log", - "object", + "object 0.33.0", "target-lexicon", "thiserror", - "wasmparser 0.201.0", - "wasmtime-cranelift-shared", + "wasmparser 0.202.0", "wasmtime-environ", "wasmtime-versioned-export-macros", ] -[[package]] -name = "wasmtime-cranelift-shared" -version = "19.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "508898cbbea0df81a5d29cfc1c7c72431a1bc4c9e89fd9514b4c868474c05c7a" -dependencies = [ - "anyhow", - "cranelift-codegen", - "cranelift-control", - "cranelift-native", - "gimli", - "object", - "target-lexicon", - "wasmtime-environ", -] - [[package]] name = "wasmtime-environ" -version = "19.0.2" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d7e3f2aa72dbb64c19708646e1ff97650f34e254598b82bad5578ea9c80edd30" +checksum = "64ffc1613db69ee47c96738861534f9a405e422a5aa00224fbf5d410b03fb445" dependencies = [ "anyhow", "bincode", @@ -2126,14 +2118,14 @@ dependencies = [ "gimli", "indexmap", "log", - "object", + "object 0.33.0", "rustc-demangle", "serde", "serde_derive", "target-lexicon", "thiserror", - "wasm-encoder 0.201.0", - "wasmparser 0.201.0", + "wasm-encoder 0.202.0", + "wasmparser 0.202.0", "wasmprinter", "wasmtime-component-util", "wasmtime-types", @@ -2141,9 +2133,9 @@ dependencies = [ [[package]] name = "wasmtime-fiber" -version = "19.0.2" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9235b643527bcbac808216ed342e1fba324c95f14a62762acfa6f2e6ca5edbd6" +checksum = "f043514a23792761c5765f8ba61a4aa7d67f260c0c37494caabceb41d8ae81de" dependencies = [ "anyhow", "cc", @@ -2156,11 +2148,11 @@ dependencies = [ [[package]] name = "wasmtime-jit-debug" -version = "19.0.2" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92de34217bf7f0464262adf391a9950eba440f9dfc7d3b0e3209302875c6f65f" +checksum = "9c0ca2ad8f5d2b37f507ef1c935687a690e84e9f325f5a2af9639440b43c1f0e" dependencies = [ - "object", + "object 0.33.0", "once_cell", "rustix", "wasmtime-versioned-export-macros", @@ -2168,9 +2160,9 @@ dependencies = [ [[package]] name = "wasmtime-jit-icache-coherence" -version = "19.0.2" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c22ca2ef4d87b23d400660373453e274b2251bc2d674e3102497f690135e04b0" +checksum = "7a9f93a3289057b26dc75eb84d6e60d7694f7d169c7c09597495de6e016a13ff" dependencies = [ "cfg-if", "libc", @@ -2179,9 +2171,9 @@ dependencies = [ [[package]] name = "wasmtime-runtime" -version = "19.0.2" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1806ee242ca4fd183309b7406e4e83ae7739b7569f395d56700de7c7ef9f5eb8" +checksum = "c6332a2b0af4224c3ea57c857ad39acd2780ccc2b0c99ba1baa01864d90d7c94" dependencies = [ "anyhow", "cc", @@ -2190,47 +2182,47 @@ dependencies = [ "indexmap", "libc", "log", - "mach", + "mach2", "memfd", "memoffset", "paste", "psm", "rustix", "sptr", - "wasm-encoder 0.201.0", + "wasm-encoder 0.202.0", "wasmtime-asm-macros", "wasmtime-environ", "wasmtime-fiber", "wasmtime-jit-debug", + "wasmtime-slab", "wasmtime-versioned-export-macros", - "wasmtime-wmemcheck", "windows-sys 0.52.0", ] [[package]] name = "wasmtime-slab" -version = "19.0.2" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "20c58bef9ce877fd06acb58f08d003af17cb05cc51225b455e999fbad8e584c0" +checksum = "8b3655075824a374c536a2b2cc9283bb765fcdf3d58b58587862c48571ad81ef" [[package]] name = "wasmtime-types" -version = "19.0.2" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cebe297aa063136d9d2e5b347c1528868aa43c2c8d0e1eb0eec144567e38fe0f" +checksum = "b98cf64a242b0b9257604181ca28b28a5fcaa4c9ea1d396f76d1d2d1c5b40eef" dependencies = [ "cranelift-entity", "serde", "serde_derive", "thiserror", - "wasmparser 0.201.0", + "wasmparser 0.202.0", ] [[package]] name = "wasmtime-versioned-export-macros" -version = "19.0.2" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffaafa5c12355b1a9ee068e9295d50c4ca0a400c721950cdae4f5b54391a2da5" +checksum = "8561d9e2920db2a175213d557d71c2ac7695831ab472bbfafb9060cd1034684f" dependencies = [ "proc-macro2", "quote", @@ -2239,9 +2231,9 @@ dependencies = [ [[package]] name = "wasmtime-wasi" -version = "19.0.2" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b95961546319d4019625920756967a929879d1d46c4e5f89a74e9f4405655b0c" +checksum = "34e1f53a9d4688a138282580fa7a46cbf1a41524f0e50c7e402e1407246f0155" dependencies = [ "anyhow", "async-trait", @@ -2270,39 +2262,33 @@ dependencies = [ [[package]] name = "wasmtime-winch" -version = "19.0.2" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d618b4e90d3f259b1b77411ce573c9f74aade561957102132e169918aabdc863" +checksum = "a06b573d14ac846a0fb8c541d8fca6a64acf9a1d176176982472274ab1d2fa5d" dependencies = [ "anyhow", "cranelift-codegen", "gimli", - "object", + "object 0.33.0", "target-lexicon", - "wasmparser 0.201.0", - "wasmtime-cranelift-shared", + "wasmparser 0.202.0", + "wasmtime-cranelift", "wasmtime-environ", "winch-codegen", ] [[package]] name = "wasmtime-wit-bindgen" -version = "19.0.2" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c7a253c8505edd7493603e548bff3af937b0b7dbf2b498bd5ff2131b651af72" +checksum = "595bc7bb3b0ff4aa00fab718c323ea552c3034d77abc821a35112552f2ea487a" dependencies = [ "anyhow", "heck 0.4.1", "indexmap", - "wit-parser 0.201.0", + "wit-parser 0.202.0", ] -[[package]] -name = "wasmtime-wmemcheck" -version = "19.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9a8c62e9df8322b2166d2a6f096fbec195ddb093748fd74170dcf25ef596769" - [[package]] name = "wast" version = "35.0.2" @@ -2359,9 +2345,9 @@ dependencies = [ [[package]] name = "wiggle" -version = "19.0.2" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "899d3fe5fbacd02f114cacdaa1cca9040280c4153c71833a77b9609c60ccf72b" +checksum = "1b6552dda951239e219c329e5a768393664e8d120c5e0818487ac2633f173b1f" dependencies = [ "anyhow", "async-trait", @@ -2374,9 +2360,9 @@ dependencies = [ [[package]] name = "wiggle-generate" -version = "19.0.2" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2df5887f452cff44ffe1e1aba69b7fafe812deed38498446fa7a46b55e962cd5" +checksum = "da64cb31e0bfe8b1d2d13956ef9fd5c77545756a1a6ef0e6cfd44e8f1f207aed" dependencies = [ "anyhow", "heck 0.4.1", @@ -2389,9 +2375,9 @@ dependencies = [ [[package]] name = "wiggle-macro" -version = "19.0.2" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "acdb12de36507498abaa3a042f895a43ee00a2f6125b6901b9a27edf72bfdbe7" +checksum = "900b2416ef2ff2903ded6cf55d4a941fed601bf56a8c4874856d7a77c1891994" dependencies = [ "proc-macro2", "quote", @@ -2423,9 +2409,9 @@ checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" [[package]] name = "winch-codegen" -version = "0.17.2" +version = "0.18.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2d15869abc9e3bb29c017c003dbe007a08e9910e8ff9023a962aa13c1b2ee6af" +checksum = "fb23450977f9d4a23c02439cf6899340b2d68887b19465c5682740d9cc37d52e" dependencies = [ "anyhow", "cranelift-codegen", @@ -2433,7 +2419,8 @@ dependencies = [ "regalloc2", "smallvec", "target-lexicon", - "wasmparser 0.201.0", + "wasmparser 0.202.0", + "wasmtime-cranelift", "wasmtime-environ", ] @@ -2625,9 +2612,9 @@ dependencies = [ [[package]] name = "wit-parser" -version = "0.201.0" +version = "0.202.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "196d3ecfc4b759a8573bf86a9b3f8996b304b3732e4c7de81655f875f6efdca6" +checksum = "744237b488352f4f27bca05a10acb79474415951c450e52ebd0da784c1df2bcc" dependencies = [ "anyhow", "id-arena", @@ -2638,7 +2625,7 @@ dependencies = [ "serde_derive", "serde_json", "unicode-xid", - "wasmparser 0.201.0", + "wasmparser 0.202.0", ] [[package]] diff --git a/Cargo.toml b/Cargo.toml index 7388af0..c25ee53 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -21,8 +21,8 @@ nom_locate = "4.2" rustyline = "14.0.0" tokio = { version = "1.36.0", features = ["macros"] } -wasmtime = { version = "19.0.2", features = ["component-model"] } -wasmtime-wasi = { version = "19.0.2" } +wasmtime = { version = "20.0.0", features = ["component-model"] } +wasmtime-wasi = { version = "20.0.0" } wit-component = "0.205.0" wit-parser = "0.205.0" wasm-compose = "0.205.0" diff --git a/src/command.rs b/src/command.rs index 9439393..9a85bea 100644 --- a/src/command.rs +++ b/src/command.rs @@ -323,11 +323,11 @@ fn format_val(val: &Val) -> String { Val::Float32(f) => f.to_string(), Val::Float64(f) => f.to_string(), Val::Char(c) => c.to_string(), - Val::Option(o) => match o.value() { + Val::Option(o) => match o { Some(o) => format!("some({})", format_val(o)), None => "none".into(), }, - Val::Result(r) => match r.value() { + Val::Result(r) => match r { Ok(Some(o)) => format!("ok({})", format_val(o)), Ok(None) => "ok".to_string(), Err(Some(e)) => format!("err({})", format_val(e)), @@ -343,14 +343,14 @@ fn format_val(val: &Val) -> String { } Val::Record(r) => { let fields = r - .fields() + .iter() .map(|(key, value)| format!("{}: {}", key, format_val(value))) .collect::>() .join(", "); format!("{{ {fields} }}") } Val::Tuple(_) => todo!(), - Val::Variant(_) => todo!(), + Val::Variant(..) => todo!(), Val::Enum(_) => todo!(), Val::Flags(_) => todo!(), Val::Resource(_) => todo!(), @@ -377,7 +377,7 @@ fn val_as_type(val: &Val) -> &'static str { Val::List(_) => "list", Val::Record(_) => "record", Val::Tuple(_) => todo!(), - Val::Variant(_) => todo!(), + Val::Variant(..) => todo!(), Val::Enum(_) => todo!(), Val::Flags(_) => todo!(), Val::Resource(_) => todo!(), diff --git a/src/evaluator.rs b/src/evaluator.rs index 12a28a7..37706e2 100644 --- a/src/evaluator.rs +++ b/src/evaluator.rs @@ -1,7 +1,7 @@ use std::collections::HashMap; use anyhow::{bail, Context}; -use wasmtime::component::{self, List, Record, Val}; +use wasmtime::component::{self, Val}; use crate::{command::parser, runtime::Runtime, wit::WorldResolver}; @@ -47,19 +47,19 @@ impl<'a> Evaluator<'a> { if ident.interface.is_none() && ident.item == "some" && args.len() == 1 => { let val = self.eval(args.remove(0), Some(&o.ty()))?; - return o.new_val(Some(val)); + return Ok(val); } Some(component::Type::Result(r)) if args.len() == 1 => { if let Some(ok) = r.ok() { if ident.interface.is_none() && ident.item == "ok" { let val = self.eval(args.remove(0), Some(&ok))?; - return r.new_val(Ok(Some(val))); + return Ok(val); } } if let Some(err) = r.err() { if ident.interface.is_none() && ident.item == "err" { let val = self.eval(args.remove(0), Some(&err))?; - return r.new_val(Err(Some(val))); + return Ok(Val::Result(Err(Some(Box::new(val))))); } } } @@ -126,7 +126,7 @@ impl<'a> Evaluator<'a> { for item in list.items { values.push(self.eval(item, Some(&l.ty()))?) } - Ok(Val::List(List::new(&l, values.into_boxed_slice())?)) + Ok(Val::List(values)) } Some(component::Type::Option(o)) => match o.ty() { component::Type::List(l) => { @@ -134,10 +134,12 @@ impl<'a> Evaluator<'a> { for item in list.items { values.push(self.eval(item, Some(&l.ty()))?) } - Ok(Val::Option(component::OptionVal::new( - o, - Some(Val::List(List::new(&l, values.into_boxed_slice())?)), - )?)) + let o = match values.len() { + 0 => None, + 1 => values.pop().map(Box::new), + _ => todo!("should this be unreachable, or other logic to create this option?"), + }; + Ok(Val::Option(o)) } t => bail!( "type error - required option<{}> found = list", @@ -177,18 +179,21 @@ impl<'a> Evaluator<'a> { .sort_by(|(f1, _), (f2, _)| types.get(f1).unwrap().cmp(types.get(f2).unwrap())); for ((name, field_expr), field_type) in r.fields.into_iter().zip(ty.fields()) { - values.push((name, self.eval(field_expr, Some(&field_type.ty))?)); + values.push((name.to_string(), self.eval(field_expr, Some(&field_type.ty))?)); } - Ok(Val::Record(Record::new(ty, values)?)) + //Ok(Val::Record(Record::new(ty, values)?)) + Ok(Val::Record(values)) } parser::Literal::String(s) => { let val = Val::String(s.to_owned().into()); match type_hint { - Some(component::Type::Result(r)) => r.new_val(match (r.ok(), r.err()) { - (Some(_), _) => Ok(Some(val)), - (_, Some(_)) => Err(Some(val)), - (None, None) => return Ok(val), - }), + Some(component::Type::Result(r)) => { + Ok(Val::Result( match (r.ok(), r.err()) { + (Some(_), _) => Ok(Some(Box::new(val))), + (_, Some(_)) => Err(Some(Box::new(val))), + (None, None) => return Ok(val), + })) + }, _ => Ok(val), } } @@ -209,21 +214,22 @@ impl<'a> Evaluator<'a> { Some(t) => match t { component::Type::Bool if ident == "true" => Ok(Val::Bool(true)), component::Type::Bool if ident == "false" => Ok(Val::Bool(false)), - component::Type::Enum(e) => e.new_val(ident), - component::Type::Variant(v) => match self.lookup_in_scope(ident) { + component::Type::Enum(_e) => Ok(Val::Enum(ident.to_string())), // TODO (fsr): should _e be used in building the String? + component::Type::Variant(_) => match self.lookup_in_scope(ident) { Ok(v) => Ok(v), - Err(_) => v.new_val(ident, None), + Err(_) => Ok(Val::Variant(ident.to_string(), None)), + }, - component::Type::Option(o) if ident == "none" => o.new_val(None), + component::Type::Option(_) if ident == "none" => Ok(Val::Option(None)), component::Type::Option(o) => { - o.new_val(Some(self.resolve_ident(ident, Some(&o.ty()))?)) + Ok(Val::Option(Some(Box::new(self.resolve_ident(ident, Some(&o.ty()))?)))) } - component::Type::Result(r) => r.new_val(match (r.ok(), r.err()) { - (Some(o), _) => Ok(Some(self.resolve_ident(ident, Some(&o))?)), + component::Type::Result(r) => Ok(Val::Result(match (r.ok(), r.err()) { + (Some(o), _) => Ok(Some(Box::new(self.resolve_ident(ident, Some(&o))?))), (None, None) if ident == "ok" => Ok(None), (None, None) if ident == "err" => Err(None), _ => return self.lookup_in_scope(ident), - }), + })), component::Type::Bool | component::Type::U8 | component::Type::U16 diff --git a/src/runtime.rs b/src/runtime.rs index 32e295a..a33de56 100644 --- a/src/runtime.rs +++ b/src/runtime.rs @@ -42,7 +42,7 @@ impl Runtime { let imports_wasi_cli = resolver.imports_wasi_cli(); if imports_wasi_cli { log::debug!("Linking with wasi"); - wasmtime_wasi::command::sync::add_to_linker(&mut linker)?; + wasmtime_wasi::add_to_linker_sync(&mut linker)?; } for (import_name, import) in resolver.imports(!imports_wasi_cli) { let import_name = resolver.world_item_name(import_name); @@ -51,7 +51,7 @@ impl Runtime { wit_parser::WorldItem::Function(f) => { linker .root() - .func_new(&component, &f.name, move |_ctx, _args, _rets| { + .func_new(&f.name, move |_ctx, _args, _rets| { stub_import(&import_name); Ok(()) })?; @@ -63,7 +63,7 @@ impl Runtime { for (_, f) in interface.functions.iter() { let stub_import = stub_import.clone(); let import_name = import_name.clone(); - instance.func_new(&component, &f.name, move |_ctx, _args, _rets| { + instance.func_new(&f.name, move |_ctx, _args, _rets| { stub_import(&import_name); Ok(()) })?; @@ -167,7 +167,7 @@ impl Runtime { ) -> anyhow::Result<()> { let component = load_component(&self.engine, component_bytes)?; let mut linker = Linker::::new(&self.engine); - wasmtime_wasi::command::sync::add_to_linker(&mut linker)?; + wasmtime_wasi::add_to_linker_sync(&mut linker)?; let mut root = self.linker.root(); let mut import_instance = root .instance(&import_ident.to_string()) @@ -238,7 +238,6 @@ impl Runtime { .with_context(|| format!("no exported function named '{fun_name}' found"))? }; import_instance.func_new( - &self.component.0, &fun_name, move |_ctx, args, results| { let mut store = store.lock().unwrap(); @@ -277,7 +276,7 @@ impl Runtime { let component = load_component(&self.engine, component_bytes)?; let mut linker = Linker::::new(&self.engine); - wasmtime_wasi::command::sync::add_to_linker(&mut linker)?; + wasmtime_wasi::add_to_linker_sync(&mut linker)?; let export_func = { let mut store_lock = self.import_impls.store.lock().unwrap(); let export_instance = linker.instantiate(&mut *store_lock, &component)?; @@ -302,7 +301,7 @@ impl Runtime { .linker .instance(&interface.to_string()) .with_context(|| format!("no interface named '{interface}' found"))?; - instance.func_new(&self.component.0, &name, move |_ctx, args, results| { + instance.func_new(&name, move |_ctx, args, results| { let mut store = store.lock().unwrap(); export_func.call(&mut *store, args, results)?; export_func.post_return(&mut *store)?; @@ -311,7 +310,6 @@ impl Runtime { } None => { self.linker.root().func_new( - &self.component.0, &name, move |_ctx, args, results| { let mut store = store.lock().unwrap(); From 401e0fe158dff5e537af121964b21a4615b97e7b Mon Sep 17 00:00:00 2001 From: Frank Rehwinkel Date: Thu, 25 Apr 2024 13:49:31 -0400 Subject: [PATCH 08/20] fix multiple args --- src/command/parser.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/command/parser.rs b/src/command/parser.rs index f895906..3af17d5 100644 --- a/src/command/parser.rs +++ b/src/command/parser.rs @@ -235,6 +235,7 @@ impl<'a> FunctionCall<'a> { if input.front().map(|t| t.token()) != Some(TokenKind::Comma) { break; } + input.pop_front(); } expect_token(input, |t| t == TokenKind::ClosedParen)?; Ok(Some(FunctionCall { From ad9d89efff6e81fcc9066019b1786b4c963074b9 Mon Sep 17 00:00:00 2001 From: Frank Rehwinkel Date: Thu, 25 Apr 2024 13:50:28 -0400 Subject: [PATCH 09/20] change val_as_type to return Cow --- src/command.rs | 57 ++++++++++++++++++++++++++++++-------------------- 1 file changed, 34 insertions(+), 23 deletions(-) diff --git a/src/command.rs b/src/command.rs index 9a85bea..34a1b29 100644 --- a/src/command.rs +++ b/src/command.rs @@ -1,6 +1,7 @@ pub mod parser; mod tokenizer; use std::collections::HashMap; +use std::borrow::Cow; use anyhow::{bail, Context as _}; use colored::Colorize; @@ -357,29 +358,39 @@ fn format_val(val: &Val) -> String { } } -fn val_as_type(val: &Val) -> &'static str { +fn val_as_type(val: &Val) -> Cow<'static, str> { match val { - Val::String(_) => "string", - Val::Bool(_) => "bool", - Val::U8(_) => "u8", - Val::U16(_) => "u16", - Val::U32(_) => "u32", - Val::U64(_) => "u64", - Val::S8(_) => "s8", - Val::S16(_) => "s16", - Val::S32(_) => "s32", - Val::S64(_) => "s64", - Val::Float32(_) => "float32", - Val::Float64(_) => "float64", - Val::Char(_) => "char", - Val::Option(_) => "option", - Val::Result(_) => "result", - Val::List(_) => "list", - Val::Record(_) => "record", - Val::Tuple(_) => todo!(), - Val::Variant(..) => todo!(), - Val::Enum(_) => todo!(), - Val::Flags(_) => todo!(), - Val::Resource(_) => todo!(), + Val::String(_) => "string".into(), + Val::Bool(_) => "bool".into(), + Val::U8(_) => "u8".into(), + Val::U16(_) => "u16".into(), + Val::U32(_) => "u32".into(), + Val::U64(_) => "u64".into(), + Val::S8(_) => "s8".into(), + Val::S16(_) => "s16".into(), + Val::S32(_) => "s32".into(), + Val::S64(_) => "s64".into(), + Val::Float32(_) => "float32".into(), + Val::Float64(_) => "float64".into(), + Val::Char(_) => "char".into(), + Val::Option(t) => if let Some(t) = t { + format!("option({})", val_as_type(t)).into() + } else { + "option(type-unknown-because-variant-was-none)".into() + }, + Val::Result(_) => "result".into(), + Val::List(t) => { + if ! t.is_empty() { + format!("list({})", val_as_type(&t[0])).into() + } else { + "list(type-unknown-because-list-was-empty)".into() + } + } + Val::Record(_) => "record".into(), + Val::Tuple(_) => "tuple".into(), + Val::Variant(..) => "variant_specific".into(), + Val::Enum(_) => "enum_type".into(), + Val::Flags(_) => "flags".into(), + Val::Resource(_) => "resource_{}".into(), } } From 2cf77b051fd43cae2d86ff3caf4f5be2b03cb8b5 Mon Sep 17 00:00:00 2001 From: Frank Rehwinkel Date: Thu, 25 Apr 2024 14:34:27 -0400 Subject: [PATCH 10/20] add tuple handling to val_as_type --- src/command.rs | 26 ++++++++++++++++++++------ 1 file changed, 20 insertions(+), 6 deletions(-) diff --git a/src/command.rs b/src/command.rs index 34a1b29..c9ebc4c 100644 --- a/src/command.rs +++ b/src/command.rs @@ -350,7 +350,14 @@ fn format_val(val: &Val) -> String { .join(", "); format!("{{ {fields} }}") } - Val::Tuple(_) => todo!(), + Val::Tuple(t) => { + let items = t + .iter() + .map(format_val) + .collect::>() + .join(", "); + format!("({items})") + }, Val::Variant(..) => todo!(), Val::Enum(_) => todo!(), Val::Flags(_) => todo!(), @@ -374,20 +381,27 @@ fn val_as_type(val: &Val) -> Cow<'static, str> { Val::Float64(_) => "float64".into(), Val::Char(_) => "char".into(), Val::Option(t) => if let Some(t) = t { - format!("option({})", val_as_type(t)).into() + format!("option<{}>", val_as_type(t)).into() } else { - "option(type-unknown-because-variant-was-none)".into() + "option".into() }, Val::Result(_) => "result".into(), Val::List(t) => { if ! t.is_empty() { - format!("list({})", val_as_type(&t[0])).into() + format!("list<{}>", val_as_type(&t[0])).into() } else { - "list(type-unknown-because-list-was-empty)".into() + "list".into() } } Val::Record(_) => "record".into(), - Val::Tuple(_) => "tuple".into(), + Val::Tuple(t) => { + let item_types = t + .iter() + .map(val_as_type) + .collect::>() + .join(", "); + format!("tuple<{item_types}>").into() + }, Val::Variant(..) => "variant_specific".into(), Val::Enum(_) => "enum_type".into(), Val::Flags(_) => "flags".into(), From ac2a9c713168418c5a20f14d11db60415fc4f2d6 Mon Sep 17 00:00:00 2001 From: Frank Rehwinkel Date: Thu, 25 Apr 2024 14:44:06 -0400 Subject: [PATCH 11/20] add record handling to val_as_type --- src/command.rs | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/command.rs b/src/command.rs index c9ebc4c..8db5cb4 100644 --- a/src/command.rs +++ b/src/command.rs @@ -393,7 +393,14 @@ fn val_as_type(val: &Val) -> Cow<'static, str> { "list".into() } } - Val::Record(_) => "record".into(), + Val::Record(r) => { + let field_types = r + .iter() + .map(|(key, value)| format!("{}: {}", key, val_as_type(value))) + .collect::>() + .join(", "); + format!("record{{ {field_types} }}").into() + } Val::Tuple(t) => { let item_types = t .iter() From 31fe6c441c611406c0b2351a34cd185f4c455ef9 Mon Sep 17 00:00:00 2001 From: Frank Rehwinkel Date: Fri, 26 Apr 2024 18:13:43 -0400 Subject: [PATCH 12/20] val_as_type minor cleanup --- src/command.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/command.rs b/src/command.rs index 8db5cb4..77709fc 100644 --- a/src/command.rs +++ b/src/command.rs @@ -337,7 +337,7 @@ fn format_val(val: &Val) -> String { Val::List(l) => { let items = l .iter() - .map(|value| format!("{}", format_val(value))) + .map(|value| format_val(value).to_string()) .collect::>() .join(", "); format!("[{items}]") @@ -412,6 +412,6 @@ fn val_as_type(val: &Val) -> Cow<'static, str> { Val::Variant(..) => "variant_specific".into(), Val::Enum(_) => "enum_type".into(), Val::Flags(_) => "flags".into(), - Val::Resource(_) => "resource_{}".into(), + Val::Resource(_) => "resource".into(), } } From 16fb19360fe1cd02a2b2762a6fbbf040a85c440c Mon Sep 17 00:00:00 2001 From: Frank Rehwinkel Date: Fri, 26 Apr 2024 18:14:19 -0400 Subject: [PATCH 13/20] add Result handling in val_as_type --- src/command.rs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/command.rs b/src/command.rs index 77709fc..26f962d 100644 --- a/src/command.rs +++ b/src/command.rs @@ -385,7 +385,12 @@ fn val_as_type(val: &Val) -> Cow<'static, str> { } else { "option".into() }, - Val::Result(_) => "result".into(), + Val::Result(r) => match r { + Ok(Some(o)) => format!("Result>", val_as_type(o)).into(), + Ok(None) => "Result".into(), + Err(Some(e)) => format!("Result>", val_as_type(e)).into(), + Err(None) => "Result".into(), + }, Val::List(t) => { if ! t.is_empty() { format!("list<{}>", val_as_type(&t[0])).into() From db90e12a0c87c67dd6789c92bc9eadbe99089057 Mon Sep 17 00:00:00 2001 From: Frank Rehwinkel Date: Mon, 6 May 2024 08:02:43 -0400 Subject: [PATCH 14/20] deps: update to wasm-tools crates 0.206.0 --- Cargo.lock | 58 ++++++++++++++++++++++++++++-------------------------- Cargo.toml | 6 +++--- 2 files changed, 33 insertions(+), 31 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index ab997fd..2605075 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1899,9 +1899,9 @@ checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" [[package]] name = "wasm-compose" -version = "0.205.0" +version = "0.206.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c2e7f958c36da29d15661a855d0162b2361de5896c9bfa98976b61b0f75c597" +checksum = "d6d4d4f62e79bd77583ea79cfeb243bbc978f29817b7c5f01c5b3b4a57607d27" dependencies = [ "anyhow", "heck 0.4.1", @@ -1913,8 +1913,8 @@ dependencies = [ "serde_derive", "serde_yaml", "smallvec", - "wasm-encoder 0.205.0", - "wasmparser 0.205.0", + "wasm-encoder 0.206.0", + "wasmparser 0.206.0", "wat", ] @@ -1929,19 +1929,19 @@ dependencies = [ [[package]] name = "wasm-encoder" -version = "0.205.0" +version = "0.206.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90e95b3563d164f33c1cfb0a7efbd5940c37710019be10cd09f800fdec8b0e5c" +checksum = "d759312e1137f199096d80a70be685899cd7d3d09c572836bb2e9b69b4dc3b1e" dependencies = [ "leb128", - "wasmparser 0.205.0", + "wasmparser 0.206.0", ] [[package]] name = "wasm-metadata" -version = "0.205.0" +version = "0.206.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e9855ad6dd4d099fa8505f01fb0b84c7e3efd5f555207329e3ad938d5f394fe7" +checksum = "84435ac34e29de6154fdb180ebbe2bdde96336f7ad0990003c43a21bd441303f" dependencies = [ "anyhow", "indexmap", @@ -1949,8 +1949,8 @@ dependencies = [ "serde_derive", "serde_json", "spdx", - "wasm-encoder 0.205.0", - "wasmparser 0.205.0", + "wasm-encoder 0.206.0", + "wasmparser 0.206.0", ] [[package]] @@ -1966,11 +1966,13 @@ dependencies = [ [[package]] name = "wasmparser" -version = "0.205.0" +version = "0.206.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d457bb52804242e09d55a306e53ddbc65d1d29ed83db6a4eea3ed412ee0cfdf" +checksum = "39192edb55d55b41963db40fd49b0b542156f04447b5b512744a91d38567bdbc" dependencies = [ + "ahash", "bitflags", + "hashbrown 0.14.3", "indexmap", "semver", ] @@ -2300,24 +2302,24 @@ dependencies = [ [[package]] name = "wast" -version = "205.0.0" +version = "206.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "441a6a195b3b5245e26d450bbcc91366c6b652382a22f63cbe3c73240e13b2bb" +checksum = "68586953ee4960b1f5d84ebf26df3b628b17e6173bc088e0acfbce431469795a" dependencies = [ "bumpalo", "leb128", "memchr", "unicode-width", - "wasm-encoder 0.205.0", + "wasm-encoder 0.206.0", ] [[package]] name = "wat" -version = "1.205.0" +version = "1.206.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19832624d606e7c6bf3cd4caa73578ecec5eac30c768269256d19c79900beb18" +checksum = "da4c6f2606276c6e991aebf441b2fc92c517807393f039992a3e0ad873efe4ad" dependencies = [ - "wast 205.0.0", + "wast 206.0.0", ] [[package]] @@ -2340,7 +2342,7 @@ dependencies = [ "wasmtime", "wasmtime-wasi", "wit-component", - "wit-parser 0.205.0", + "wit-parser 0.206.0", ] [[package]] @@ -2593,9 +2595,9 @@ dependencies = [ [[package]] name = "wit-component" -version = "0.205.0" +version = "0.206.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74841e17b2c2bfbd8ca8c45190ef85dff1c5e8659f0e2d164802ffc87dfb18c3" +checksum = "81e1ae4cace3706e29a8cf1f728b792255ecdc02653b9f4130ab6cc64f435a67" dependencies = [ "anyhow", "bitflags", @@ -2604,10 +2606,10 @@ dependencies = [ "serde", "serde_derive", "serde_json", - "wasm-encoder 0.205.0", + "wasm-encoder 0.206.0", "wasm-metadata", - "wasmparser 0.205.0", - "wit-parser 0.205.0", + "wasmparser 0.206.0", + "wit-parser 0.206.0", ] [[package]] @@ -2630,9 +2632,9 @@ dependencies = [ [[package]] name = "wit-parser" -version = "0.205.0" +version = "0.206.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3db34c7688c161ed7bd1b2f8055dca9fb2c15201db58754e9c48a0805f32e5f" +checksum = "d226de4e95e052cb664d2bdad2f31d9cad5117038a3439568f078d1afd8842fe" dependencies = [ "anyhow", "id-arena", @@ -2643,7 +2645,7 @@ dependencies = [ "serde_derive", "serde_json", "unicode-xid", - "wasmparser 0.205.0", + "wasmparser 0.206.0", ] [[package]] diff --git a/Cargo.toml b/Cargo.toml index c25ee53..3894be2 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -23,6 +23,6 @@ tokio = { version = "1.36.0", features = ["macros"] } wasmtime = { version = "20.0.0", features = ["component-model"] } wasmtime-wasi = { version = "20.0.0" } -wit-component = "0.205.0" -wit-parser = "0.205.0" -wasm-compose = "0.205.0" +wit-component = "0.206.0" +wit-parser = "0.206.0" +wasm-compose = "0.206.0" From da35ebd91ffd1ff3d52cd08751aac6f9d9257e9f Mon Sep 17 00:00:00 2001 From: Frank Rehwinkel Date: Mon, 6 May 2024 08:10:01 -0400 Subject: [PATCH 15/20] deps: update to wasmtime crates 20.0.1 --- Cargo.lock | 124 ++++++++++++++++++++++++++--------------------------- Cargo.toml | 4 +- 2 files changed, 64 insertions(+), 64 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 2605075..d22610b 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -399,18 +399,18 @@ dependencies = [ [[package]] name = "cranelift-bforest" -version = "0.107.0" +version = "0.107.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79b27922a6879b5b5361d0a084cb0b1941bf109a98540addcb932da13b68bed4" +checksum = "3c7a700bc3e2e834c81c7e9e57c6b27049172fc6156a6a406dd2265d64c30409" dependencies = [ "cranelift-entity", ] [[package]] name = "cranelift-codegen" -version = "0.107.0" +version = "0.107.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "304c455b28bf56372729acb356afbb55d622f2b0f2f7837aa5e57c138acaac4d" +checksum = "35bb55da792dc46a35e6e283b02b9d6aa7f21349691f41176d8ecf4a1494b6ad" dependencies = [ "bumpalo", "cranelift-bforest", @@ -429,33 +429,33 @@ dependencies = [ [[package]] name = "cranelift-codegen-meta" -version = "0.107.0" +version = "0.107.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1653c56b99591d07f67c5ca7f9f25888948af3f4b97186bff838d687d666f613" +checksum = "bf590672e1a7580158968898ade9c82801d6ebeaa4649d6f99f9cbb411512a8b" dependencies = [ "cranelift-codegen-shared", ] [[package]] name = "cranelift-codegen-shared" -version = "0.107.0" +version = "0.107.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f5b6a9cf6b6eb820ee3f973a0db313c05dc12d370f37b4fe9630286e1672573f" +checksum = "3ab16a95d8b10b72eaa8bb9f0ce0fdd013e5f225bea92f69d2dbd2424aae5381" [[package]] name = "cranelift-control" -version = "0.107.0" +version = "0.107.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9d06e6bf30075fb6bed9e034ec046475093392eea1aff90eb5c44c4a033d19a" +checksum = "60448a5af01f5716877e616ec1613424fb65f427320c6e6447315966507f12da" dependencies = [ "arbitrary", ] [[package]] name = "cranelift-entity" -version = "0.107.0" +version = "0.107.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29be04f931b73cdb9694874a295027471817f26f26d2f0ebe5454153176b6e3a" +checksum = "78689d6588f53981bf005b82d94125cc40cf9856b667bc276d1acdede400b633" dependencies = [ "serde", "serde_derive", @@ -463,9 +463,9 @@ dependencies = [ [[package]] name = "cranelift-frontend" -version = "0.107.0" +version = "0.107.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a07fd7393041d7faa2f37426f5dc7fc04003b70988810e8c063beefeff1cd8f9" +checksum = "c86da6e45adc39e8d66a73d6fb782b0d7961df9e44b724246e01e515f86b1f0d" dependencies = [ "cranelift-codegen", "log", @@ -475,15 +475,15 @@ dependencies = [ [[package]] name = "cranelift-isle" -version = "0.107.0" +version = "0.107.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f341d7938caa6dff8149dac05bb2b53fc680323826b83b4cf175ab9f5139a3c9" +checksum = "dcb6f70d94826074699bc350c33dab82eb6f06022a3518bb466f501569d7379e" [[package]] name = "cranelift-native" -version = "0.107.0" +version = "0.107.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82af6066e6448d26eeabb7aa26a43f7ff79f8217b06bade4ee6ef230aecc8880" +checksum = "e27ec0ef4115eb9cc15be9c841085db17233403f8ed325e02bd6a9d78d6c939c" dependencies = [ "cranelift-codegen", "libc", @@ -492,9 +492,9 @@ dependencies = [ [[package]] name = "cranelift-wasm" -version = "0.107.0" +version = "0.107.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2766fab7284a914a7f17f90ebe865c86453225fb8637ac31f123f5028fee69cd" +checksum = "fce009efc27c598ac0c019c7f3dc582403835547128aeb497edf76cb77d75250" dependencies = [ "cranelift-codegen", "cranelift-entity", @@ -1989,9 +1989,9 @@ dependencies = [ [[package]] name = "wasmtime" -version = "20.0.0" +version = "20.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a5990663c28d81015ddbb02a068ac1bf396a4ea296eba7125b2dfc7c00cb52e" +checksum = "2364a810370f08ece49d013255058c3c88ca6c0a080de66549233b7d2ca078b8" dependencies = [ "addr2line", "anyhow", @@ -2035,18 +2035,18 @@ dependencies = [ [[package]] name = "wasmtime-asm-macros" -version = "20.0.0" +version = "20.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "625ee94c72004f3ea0228989c9506596e469517d7d0ed66f7300d1067bdf1ca9" +checksum = "c52cceae147514e279460ac3c43c1ea440c51c39202842611623b3f9734f73a8" dependencies = [ "cfg-if", ] [[package]] name = "wasmtime-cache" -version = "20.0.0" +version = "20.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "98534bf28de232299e83eab33984a7a6c40c69534d6bd0ea216150b63d41a83a" +checksum = "b34056847ca9bde1d97cbc829a95d634f54d2879faa17200e55f3cddac159aea" dependencies = [ "anyhow", "base64", @@ -2064,9 +2064,9 @@ dependencies = [ [[package]] name = "wasmtime-component-macro" -version = "20.0.0" +version = "20.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64f84414a25ee3a624c8b77550f3fe7b5d8145bd3405ca58886ee6900abb6dc2" +checksum = "c8fd43a734bf424e3983363f1b7532a997edb206f52104568058e412e18db9ba" dependencies = [ "anyhow", "proc-macro2", @@ -2079,15 +2079,15 @@ dependencies = [ [[package]] name = "wasmtime-component-util" -version = "20.0.0" +version = "20.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78580bdb4e04c7da3bf98088559ca1d29382668536e4d5c7f2f966d79c390307" +checksum = "44d65e6a21c3e3482240ff03cc26f5c7ae7ee5df524c2283f39cf492ab711a15" [[package]] name = "wasmtime-cranelift" -version = "20.0.0" +version = "20.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b60df0ee08c6a536c765f69e9e8205273435b66d02dd401e938769a2622a6c1a" +checksum = "e2a6ed70499769b4d51f6f656204b0806b3d783f6ec5a8517c68e8b75ecaad19" dependencies = [ "anyhow", "cfg-if", @@ -2109,9 +2109,9 @@ dependencies = [ [[package]] name = "wasmtime-environ" -version = "20.0.0" +version = "20.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64ffc1613db69ee47c96738861534f9a405e422a5aa00224fbf5d410b03fb445" +checksum = "90f7b5dbae8c3c6586e22f063ddb9e5cbf02c09629df75e5d8710f7bf880b117" dependencies = [ "anyhow", "bincode", @@ -2135,9 +2135,9 @@ dependencies = [ [[package]] name = "wasmtime-fiber" -version = "20.0.0" +version = "20.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f043514a23792761c5765f8ba61a4aa7d67f260c0c37494caabceb41d8ae81de" +checksum = "582e7ef625be814c57b1f8c3924c8899560d315f2285436c9184a09985dc3756" dependencies = [ "anyhow", "cc", @@ -2150,9 +2150,9 @@ dependencies = [ [[package]] name = "wasmtime-jit-debug" -version = "20.0.0" +version = "20.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c0ca2ad8f5d2b37f507ef1c935687a690e84e9f325f5a2af9639440b43c1f0e" +checksum = "1bf1b989e3f648340253b76c6c58b2ade89bdf0e23edc4e911deb801fa915b18" dependencies = [ "object 0.33.0", "once_cell", @@ -2162,9 +2162,9 @@ dependencies = [ [[package]] name = "wasmtime-jit-icache-coherence" -version = "20.0.0" +version = "20.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a9f93a3289057b26dc75eb84d6e60d7694f7d169c7c09597495de6e016a13ff" +checksum = "b55b43e693c0beeca494d522f4850afca53cb46acf309483aef32a125276ee78" dependencies = [ "cfg-if", "libc", @@ -2173,9 +2173,9 @@ dependencies = [ [[package]] name = "wasmtime-runtime" -version = "20.0.0" +version = "20.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c6332a2b0af4224c3ea57c857ad39acd2780ccc2b0c99ba1baa01864d90d7c94" +checksum = "1d2b876c09b7863d8a01bf87eb45f3b121fab245f8afbff7c38c38c1c9059aee" dependencies = [ "anyhow", "cc", @@ -2203,15 +2203,15 @@ dependencies = [ [[package]] name = "wasmtime-slab" -version = "20.0.0" +version = "20.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b3655075824a374c536a2b2cc9283bb765fcdf3d58b58587862c48571ad81ef" +checksum = "05c8ddfb8ebbab6ac186bc1f8c02ed988bc9ea455fea10f72bc3a07503309b4b" [[package]] name = "wasmtime-types" -version = "20.0.0" +version = "20.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b98cf64a242b0b9257604181ca28b28a5fcaa4c9ea1d396f76d1d2d1c5b40eef" +checksum = "3fa3a1f3c0deb3034d76e7dcf340c5df670a6603019ee5b58adb70870649c769" dependencies = [ "cranelift-entity", "serde", @@ -2222,9 +2222,9 @@ dependencies = [ [[package]] name = "wasmtime-versioned-export-macros" -version = "20.0.0" +version = "20.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8561d9e2920db2a175213d557d71c2ac7695831ab472bbfafb9060cd1034684f" +checksum = "b85321f0a1cd3c859b94e728533ba00074d3eca62362acf6998be0eab6f4001c" dependencies = [ "proc-macro2", "quote", @@ -2233,9 +2233,9 @@ dependencies = [ [[package]] name = "wasmtime-wasi" -version = "20.0.0" +version = "20.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34e1f53a9d4688a138282580fa7a46cbf1a41524f0e50c7e402e1407246f0155" +checksum = "0c5966b1aa330f07ef58f83b074908ea210ee864948ae3697f8892c91104e6e3" dependencies = [ "anyhow", "async-trait", @@ -2264,9 +2264,9 @@ dependencies = [ [[package]] name = "wasmtime-winch" -version = "20.0.0" +version = "20.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a06b573d14ac846a0fb8c541d8fca6a64acf9a1d176176982472274ab1d2fa5d" +checksum = "e0d446696aa83f680d85e188670631cb7958957f63d027d6c36b945c2baa3e1e" dependencies = [ "anyhow", "cranelift-codegen", @@ -2281,9 +2281,9 @@ dependencies = [ [[package]] name = "wasmtime-wit-bindgen" -version = "20.0.0" +version = "20.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "595bc7bb3b0ff4aa00fab718c323ea552c3034d77abc821a35112552f2ea487a" +checksum = "4d1d0c83af38eb6918af9c7cbc07d39f741a7baa9ddd152e19d9f93ff627dc05" dependencies = [ "anyhow", "heck 0.4.1", @@ -2347,9 +2347,9 @@ dependencies = [ [[package]] name = "wiggle" -version = "20.0.0" +version = "20.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b6552dda951239e219c329e5a768393664e8d120c5e0818487ac2633f173b1f" +checksum = "909dcda9e41ab1f8280cf7d774fa16d240792d6fe086a88ef69a9dd97827d289" dependencies = [ "anyhow", "async-trait", @@ -2362,9 +2362,9 @@ dependencies = [ [[package]] name = "wiggle-generate" -version = "20.0.0" +version = "20.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da64cb31e0bfe8b1d2d13956ef9fd5c77545756a1a6ef0e6cfd44e8f1f207aed" +checksum = "ce431612cd480dbf925fb7c3c513dec176a57ea977bf3685726e4b0ab41a6408" dependencies = [ "anyhow", "heck 0.4.1", @@ -2377,9 +2377,9 @@ dependencies = [ [[package]] name = "wiggle-macro" -version = "20.0.0" +version = "20.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "900b2416ef2ff2903ded6cf55d4a941fed601bf56a8c4874856d7a77c1891994" +checksum = "9815f5f4b6c6e01449569469416783992ac703c8fbf83d3724dfb16a02fe2e5c" dependencies = [ "proc-macro2", "quote", @@ -2411,9 +2411,9 @@ checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" [[package]] name = "winch-codegen" -version = "0.18.0" +version = "0.18.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb23450977f9d4a23c02439cf6899340b2d68887b19465c5682740d9cc37d52e" +checksum = "720aabcf6838b31b42c7adc04d847696b066ddc5877efd6071ed5f08ae75bf20" dependencies = [ "anyhow", "cranelift-codegen", diff --git a/Cargo.toml b/Cargo.toml index 3894be2..f33856e 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -21,8 +21,8 @@ nom_locate = "4.2" rustyline = "14.0.0" tokio = { version = "1.36.0", features = ["macros"] } -wasmtime = { version = "20.0.0", features = ["component-model"] } -wasmtime-wasi = { version = "20.0.0" } +wasmtime = { version = "20.0.1", features = ["component-model"] } +wasmtime-wasi = { version = "20.0.1" } wit-component = "0.206.0" wit-parser = "0.206.0" wasm-compose = "0.206.0" From 86a7b5004a4d33e2f0f9e374c48d5820fb25469a Mon Sep 17 00:00:00 2001 From: Frank Rehwinkel Date: Mon, 6 May 2024 08:21:09 -0400 Subject: [PATCH 16/20] deps: cargo update --- Cargo.lock | 83 +++++++++++++++++++++++++++++------------------------- 1 file changed, 45 insertions(+), 38 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index d22610b..b2b79d5 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -55,47 +55,48 @@ dependencies = [ [[package]] name = "anstream" -version = "0.6.13" +version = "0.6.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d96bd03f33fe50a863e394ee9718a706f988b9079b20c3784fb726e7678b62fb" +checksum = "418c75fa768af9c03be99d17643f93f79bbba589895012a80e3452a19ddda15b" dependencies = [ "anstyle", "anstyle-parse", "anstyle-query", "anstyle-wincon", "colorchoice", + "is_terminal_polyfill", "utf8parse", ] [[package]] name = "anstyle" -version = "1.0.6" +version = "1.0.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8901269c6307e8d93993578286ac0edf7f195079ffff5ebdeea6a59ffb7e36bc" +checksum = "038dfcf04a5feb68e9c60b21c9625a54c2c0616e79b72b0fd87075a056ae1d1b" [[package]] name = "anstyle-parse" -version = "0.2.3" +version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c75ac65da39e5fe5ab759307499ddad880d724eed2f6ce5b5e8a26f4f387928c" +checksum = "c03a11a9034d92058ceb6ee011ce58af4a9bf61491aa7e1e59ecd24bd40d22d4" dependencies = [ "utf8parse", ] [[package]] name = "anstyle-query" -version = "1.0.2" +version = "1.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e28923312444cdd728e4738b3f9c9cac739500909bb3d3c94b43551b16517648" +checksum = "a64c907d4e79225ac72e2a354c9ce84d50ebb4586dee56c82b3ee73004f537f5" dependencies = [ "windows-sys 0.52.0", ] [[package]] name = "anstyle-wincon" -version = "3.0.2" +version = "3.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1cd54b81ec8d6180e24654d0b371ad22fc3dd083b6ff8ba325b72e00c87660a7" +checksum = "61a38449feb7068f52bb06c12759005cf459ee52bb4adc1d5a7c4322d716fb19" dependencies = [ "anstyle", "windows-sys 0.52.0", @@ -126,9 +127,9 @@ dependencies = [ [[package]] name = "autocfg" -version = "1.2.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1fdabc7756949593fe60f30ec81974b613357de856987752631dea1e3394c80" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "backtrace" @@ -287,9 +288,9 @@ dependencies = [ [[package]] name = "cc" -version = "1.0.95" +version = "1.0.97" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d32a725bc159af97c3e629873bb9f88fb8cf8a4867175f76dc987815ea07c83b" +checksum = "099a5357d84c4c61eb35fc8eafa9a79a902c2f76911e5747ced4e032edd8d9b4" dependencies = [ "jobserver", "libc", @@ -359,9 +360,9 @@ dependencies = [ [[package]] name = "colorchoice" -version = "1.0.0" +version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "acbf1af155f9b9ef647e42cdc158db4b64a1b61f743629225fde6f3e0be2a7c7" +checksum = "0b6a852b24ab71dffc585bcb46eaf7959d175cb865a7152e35b348d1b2960422" [[package]] name = "colored" @@ -420,7 +421,7 @@ dependencies = [ "cranelift-entity", "cranelift-isle", "gimli", - "hashbrown 0.14.3", + "hashbrown 0.14.5", "log", "regalloc2", "smallvec", @@ -845,9 +846,9 @@ dependencies = [ [[package]] name = "hashbrown" -version = "0.14.3" +version = "0.14.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "290f1a1d9242c78d09ce40a5e87e7554ee637af1351968159f4952f028f75604" +checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" dependencies = [ "ahash", ] @@ -945,7 +946,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" dependencies = [ "equivalent", - "hashbrown 0.14.3", + "hashbrown 0.14.5", "serde", ] @@ -971,6 +972,12 @@ version = "2.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" +[[package]] +name = "is_terminal_polyfill" +version = "1.70.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8478577c03552c21db0e2724ffb8986a5ce7af88107e6be5d2ee6e158c12800" + [[package]] name = "itertools" version = "0.12.1" @@ -1038,9 +1045,9 @@ checksum = "884e2677b40cc8c339eaefcb701c32ef1fd2493d71118dc0ca4b6a736c93bd67" [[package]] name = "libc" -version = "0.2.153" +version = "0.2.154" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c198f91728a82281a64e1f4f9eeb25d82cb32a5de251c6bd1b5154d63a8e7bd" +checksum = "ae743338b92ff9146ce83992f766a31066a91a8c84a45e0e9f21e7cf6de6d346" [[package]] name = "libredox" @@ -1197,7 +1204,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d8dd6c0cdf9429bce006e1362bfce61fa1bfd8c898a643ed8d2b471934701d3d" dependencies = [ "crc32fast", - "hashbrown 0.14.3", + "hashbrown 0.14.5", "indexmap", "memchr", ] @@ -1466,18 +1473,18 @@ checksum = "92d43fe69e652f3df9bdc2b85b2854a0825b86e4fb76bc44d945137d053639ca" [[package]] name = "serde" -version = "1.0.198" +version = "1.0.200" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9846a40c979031340571da2545a4e5b7c4163bdae79b301d5f86d03979451fcc" +checksum = "ddc6f9cc94d67c0e21aaf7eda3a010fd3af78ebf6e096aa6e2e13c79749cce4f" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.198" +version = "1.0.200" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e88edab869b01783ba905e7d0153f9fc1a6505a96e4ad3018011eedb838566d9" +checksum = "856f046b9400cee3c8c94ed572ecdb752444c24528c035cd35882aad6f492bcb" dependencies = [ "proc-macro2", "quote", @@ -1561,9 +1568,9 @@ checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "socket2" -version = "0.5.6" +version = "0.5.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05ffd9c0a93b7543e062e759284fcf5f5e3b098501104bfbdde4d404db792871" +checksum = "ce305eb0b4296696835b71df73eb912e0f1ffd2556a501fcede6e0c50349191c" dependencies = [ "libc", "windows-sys 0.52.0", @@ -1792,9 +1799,9 @@ checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" [[package]] name = "unicode-width" -version = "0.1.11" +version = "0.1.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e51733f11c9c4f72aa0c160008246859e340b00807569a0da0e7a1079b27ba85" +checksum = "68f5e5f3158ecfd4b8ff6fe086db7c8467a2dfdac97fe420f2b7c4aa97af66d6" [[package]] name = "unicode-xid" @@ -1972,7 +1979,7 @@ checksum = "39192edb55d55b41963db40fd49b0b542156f04447b5b512744a91d38567bdbc" dependencies = [ "ahash", "bitflags", - "hashbrown 0.14.3", + "hashbrown 0.14.5", "indexmap", "semver", ] @@ -2576,9 +2583,9 @@ checksum = "bec47e5bfd1bff0eeaf6d8b485cc1074891a197ab4225d504cb7a1ab88b02bf0" [[package]] name = "winnow" -version = "0.6.6" +version = "0.6.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0c976aaaa0e1f90dbb21e9587cdaf1d9679a1cde8875c0d6bd83ab96a208352" +checksum = "c3c52e9c97a68071b23e836c9380edae937f17b9c4667bd021973efc689f618d" dependencies = [ "memchr", ] @@ -2662,18 +2669,18 @@ dependencies = [ [[package]] name = "zerocopy" -version = "0.7.32" +version = "0.7.33" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74d4d3961e53fa4c9a25a8637fc2bfaf2595b3d3ae34875568a5cf64787716be" +checksum = "087eca3c1eaf8c47b94d02790dd086cd594b912d2043d4de4bfdd466b3befb7c" dependencies = [ "zerocopy-derive", ] [[package]] name = "zerocopy-derive" -version = "0.7.32" +version = "0.7.33" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ce1b18ccd8e73a9321186f97e46f9f04b778851177567b1975109d26a08d2a6" +checksum = "6f4b6c273f496d8fd4eaf18853e6b448760225dc030ff2c485a786859aea6393" dependencies = [ "proc-macro2", "quote", From c4c8116624e0377fd1eb02704719e9bcb94bb841 Mon Sep 17 00:00:00 2001 From: Frank Rehwinkel Date: Mon, 6 May 2024 08:24:42 -0400 Subject: [PATCH 17/20] comment cleanup --- src/evaluator.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/evaluator.rs b/src/evaluator.rs index 37706e2..a40d767 100644 --- a/src/evaluator.rs +++ b/src/evaluator.rs @@ -181,7 +181,6 @@ impl<'a> Evaluator<'a> { for ((name, field_expr), field_type) in r.fields.into_iter().zip(ty.fields()) { values.push((name.to_string(), self.eval(field_expr, Some(&field_type.ty))?)); } - //Ok(Val::Record(Record::new(ty, values)?)) Ok(Val::Record(values)) } parser::Literal::String(s) => { @@ -214,7 +213,7 @@ impl<'a> Evaluator<'a> { Some(t) => match t { component::Type::Bool if ident == "true" => Ok(Val::Bool(true)), component::Type::Bool if ident == "false" => Ok(Val::Bool(false)), - component::Type::Enum(_e) => Ok(Val::Enum(ident.to_string())), // TODO (fsr): should _e be used in building the String? + component::Type::Enum(_e) => Ok(Val::Enum(ident.to_string())), component::Type::Variant(_) => match self.lookup_in_scope(ident) { Ok(v) => Ok(v), Err(_) => Ok(Val::Variant(ident.to_string(), None)), From 2a77332df111a007ee4a9df42ab5d5affb7f9901 Mon Sep 17 00:00:00 2001 From: Frank Rehwinkel Date: Tue, 7 May 2024 16:50:32 -0400 Subject: [PATCH 18/20] deps: update to wasmtime crates 20.0.2 --- Cargo.lock | 172 ++++++++++++++++++++++++++--------------------------- Cargo.toml | 4 +- 2 files changed, 88 insertions(+), 88 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index b2b79d5..44877fe 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -104,9 +104,9 @@ dependencies = [ [[package]] name = "anyhow" -version = "1.0.82" +version = "1.0.83" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f538837af36e6f6a9be0faa67f9a314f8119e4e4b5867c6ab40ed60360142519" +checksum = "25bdb32cbbdce2b519a9cd7df3a678443100e265d5e25ca763b7572a5104f5f3" [[package]] name = "arbitrary" @@ -400,18 +400,18 @@ dependencies = [ [[package]] name = "cranelift-bforest" -version = "0.107.1" +version = "0.107.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c7a700bc3e2e834c81c7e9e57c6b27049172fc6156a6a406dd2265d64c30409" +checksum = "ebf72ceaf38f7d41194d0cf6748214d8ef7389167fe09aad80f87646dbfa325b" dependencies = [ "cranelift-entity", ] [[package]] name = "cranelift-codegen" -version = "0.107.1" +version = "0.107.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35bb55da792dc46a35e6e283b02b9d6aa7f21349691f41176d8ecf4a1494b6ad" +checksum = "9ee7fde5cd9173f00ce02c491ee9e306d64740f4b1a697946e0474f389999e13" dependencies = [ "bumpalo", "cranelift-bforest", @@ -430,33 +430,33 @@ dependencies = [ [[package]] name = "cranelift-codegen-meta" -version = "0.107.1" +version = "0.107.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf590672e1a7580158968898ade9c82801d6ebeaa4649d6f99f9cbb411512a8b" +checksum = "b49bec6a517e78d4067500dc16acb558e772491a2bcb37301127448adfb8413c" dependencies = [ "cranelift-codegen-shared", ] [[package]] name = "cranelift-codegen-shared" -version = "0.107.1" +version = "0.107.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ab16a95d8b10b72eaa8bb9f0ce0fdd013e5f225bea92f69d2dbd2424aae5381" +checksum = "ead4ea497b2dc2ac31fcabd6d5d0d5dc25b3964814122e343724bdf65a53c843" [[package]] name = "cranelift-control" -version = "0.107.1" +version = "0.107.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60448a5af01f5716877e616ec1613424fb65f427320c6e6447315966507f12da" +checksum = "f81e8028c8d711ea7592648e70221f2e54acb8665f7ecd49545f021ec14c3341" dependencies = [ "arbitrary", ] [[package]] name = "cranelift-entity" -version = "0.107.1" +version = "0.107.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78689d6588f53981bf005b82d94125cc40cf9856b667bc276d1acdede400b633" +checksum = "32acd0632ba65c2566e75f64af9ef094bb8d90e58a9fbd33d920977a9d85c054" dependencies = [ "serde", "serde_derive", @@ -464,9 +464,9 @@ dependencies = [ [[package]] name = "cranelift-frontend" -version = "0.107.1" +version = "0.107.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c86da6e45adc39e8d66a73d6fb782b0d7961df9e44b724246e01e515f86b1f0d" +checksum = "a395a704934aa944ba8939cac9001174b9ae5236f48bc091f89e33bb968336f6" dependencies = [ "cranelift-codegen", "log", @@ -476,15 +476,15 @@ dependencies = [ [[package]] name = "cranelift-isle" -version = "0.107.1" +version = "0.107.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcb6f70d94826074699bc350c33dab82eb6f06022a3518bb466f501569d7379e" +checksum = "b325ce81c4ee7082dc894537eb342c37898e14230fe7c02ea945691db3e2dd01" [[package]] name = "cranelift-native" -version = "0.107.1" +version = "0.107.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e27ec0ef4115eb9cc15be9c841085db17233403f8ed325e02bd6a9d78d6c939c" +checksum = "ea11f5ac85996fa093075d66397922d4f56085d5d84ec13043d0cd4f159c6818" dependencies = [ "cranelift-codegen", "libc", @@ -493,9 +493,9 @@ dependencies = [ [[package]] name = "cranelift-wasm" -version = "0.107.1" +version = "0.107.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fce009efc27c598ac0c019c7f3dc582403835547128aeb497edf76cb77d75250" +checksum = "e4f175d4e299a8edabfbd64fa93c7650836cc8ad7f4879f9bd2632575a1f12d0" dependencies = [ "cranelift-codegen", "cranelift-entity", @@ -815,9 +815,9 @@ dependencies = [ [[package]] name = "getrandom" -version = "0.2.14" +version = "0.2.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94b22e06ecb0110981051723910cbf0b5f5e09a2062dd7663334ee79a9d1286c" +checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" dependencies = [ "cfg-if", "libc", @@ -1217,9 +1217,9 @@ checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" [[package]] name = "paste" -version = "1.0.14" +version = "1.0.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "de3145af08024dea9fa9914f381a17b8fc6034dfb00f3a84013f7ff43f29ed4c" +checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" [[package]] name = "percent-encoding" @@ -1263,9 +1263,9 @@ checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" [[package]] name = "proc-macro2" -version = "1.0.81" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d1597b0c024618f09a9c3b8655b7e430397a36d23fdafec26d6965e9eec3eba" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] @@ -1412,9 +1412,9 @@ checksum = "adad44e29e4c806119491a7f06f03de4d1af22c3a680dd47f1e6e179439d1f56" [[package]] name = "rustc-demangle" -version = "0.1.23" +version = "0.1.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d626bb9dae77e28219937af045c257c28bfd3f69333c512553507f5f9798cb76" +checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" [[package]] name = "rustc-hash" @@ -1461,15 +1461,15 @@ dependencies = [ [[package]] name = "ryu" -version = "1.0.17" +version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e86697c916019a8588c99b5fac3cead74ec0b4b819707a682fd4d23fa0ce1ba1" +checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" [[package]] name = "semver" -version = "1.0.22" +version = "1.0.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92d43fe69e652f3df9bdc2b85b2854a0825b86e4fb76bc44d945137d053639ca" +checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" [[package]] name = "serde" @@ -1605,9 +1605,9 @@ checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" [[package]] name = "syn" -version = "2.0.60" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "909518bc7b1c9b779f1bbf07f2929d35af9f0f37e47c6e9ef7f9dddc1e1821f3" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -1638,18 +1638,18 @@ checksum = "e1fc403891a21bcfb7c37834ba66a547a8f402146eba7265b5a6d88059c9ff2f" [[package]] name = "thiserror" -version = "1.0.59" +version = "1.0.60" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0126ad08bff79f29fc3ae6a55cc72352056dfff61e3ff8bb7129476d44b23aa" +checksum = "579e9083ca58dd9dcf91a9923bb9054071b9ebbd800b342194c9feb0ee89fc18" dependencies = [ "thiserror-impl", ] [[package]] name = "thiserror-impl" -version = "1.0.59" +version = "1.0.60" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d1cd413b5d558b4c5bf3680e324a6fa5014e7b7c067a51e69dbdf47eb7148b66" +checksum = "e2470041c06ec3ac1ab38d0356a6119054dedaea53e12fbefc0de730a1c08524" dependencies = [ "proc-macro2", "quote", @@ -1996,9 +1996,9 @@ dependencies = [ [[package]] name = "wasmtime" -version = "20.0.1" +version = "20.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2364a810370f08ece49d013255058c3c88ca6c0a080de66549233b7d2ca078b8" +checksum = "4af5cb32045daee8476711eb12b8b71275c2dd1fc7a58cc2a11b33ce9205f6a2" dependencies = [ "addr2line", "anyhow", @@ -2042,18 +2042,18 @@ dependencies = [ [[package]] name = "wasmtime-asm-macros" -version = "20.0.1" +version = "20.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c52cceae147514e279460ac3c43c1ea440c51c39202842611623b3f9734f73a8" +checksum = "7515c4d24c8b55c0feab67e3d52a42f999fda8b9cfafbd69a82ed6bcf299d26e" dependencies = [ "cfg-if", ] [[package]] name = "wasmtime-cache" -version = "20.0.1" +version = "20.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b34056847ca9bde1d97cbc829a95d634f54d2879faa17200e55f3cddac159aea" +checksum = "c3aa2de7189ea6b3270727d0027790494aec5e7101ca50da3f9549a86628cae4" dependencies = [ "anyhow", "base64", @@ -2071,9 +2071,9 @@ dependencies = [ [[package]] name = "wasmtime-component-macro" -version = "20.0.1" +version = "20.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c8fd43a734bf424e3983363f1b7532a997edb206f52104568058e412e18db9ba" +checksum = "794839a710a39a12677c67ff43fec54ef00d0ca6c6f631209a7c5524522221d3" dependencies = [ "anyhow", "proc-macro2", @@ -2086,15 +2086,15 @@ dependencies = [ [[package]] name = "wasmtime-component-util" -version = "20.0.1" +version = "20.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "44d65e6a21c3e3482240ff03cc26f5c7ae7ee5df524c2283f39cf492ab711a15" +checksum = "7839a1b9e15d17be1cb2a105f18be8e0bbf52bdec7a7cd6eb5d80d4c2cdf74f0" [[package]] name = "wasmtime-cranelift" -version = "20.0.1" +version = "20.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2a6ed70499769b4d51f6f656204b0806b3d783f6ec5a8517c68e8b75ecaad19" +checksum = "57ec2d9a4b9990bea53a5dfd689d48663dbd19a46903eaf73e2022b3d1ef20d3" dependencies = [ "anyhow", "cfg-if", @@ -2116,9 +2116,9 @@ dependencies = [ [[package]] name = "wasmtime-environ" -version = "20.0.1" +version = "20.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90f7b5dbae8c3c6586e22f063ddb9e5cbf02c09629df75e5d8710f7bf880b117" +checksum = "ad72e2e3f7ea5b50fedf66dd36ba24634e4f445c370644683b433d45d88f6126" dependencies = [ "anyhow", "bincode", @@ -2142,9 +2142,9 @@ dependencies = [ [[package]] name = "wasmtime-fiber" -version = "20.0.1" +version = "20.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "582e7ef625be814c57b1f8c3924c8899560d315f2285436c9184a09985dc3756" +checksum = "4dbdf3053e7e7ced0cd4ed76579995b62169a1a43696890584eae2de2e33bf54" dependencies = [ "anyhow", "cc", @@ -2157,9 +2157,9 @@ dependencies = [ [[package]] name = "wasmtime-jit-debug" -version = "20.0.1" +version = "20.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bf1b989e3f648340253b76c6c58b2ade89bdf0e23edc4e911deb801fa915b18" +checksum = "983ca409f2cd66385ce49486c022da0128acb7910c055beb5230998b49c6084c" dependencies = [ "object 0.33.0", "once_cell", @@ -2169,9 +2169,9 @@ dependencies = [ [[package]] name = "wasmtime-jit-icache-coherence" -version = "20.0.1" +version = "20.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b55b43e693c0beeca494d522f4850afca53cb46acf309483aef32a125276ee78" +checksum = "ede45379f3b4d395d8947006de8043801806099a240a26db553919b68e96ab15" dependencies = [ "cfg-if", "libc", @@ -2180,9 +2180,9 @@ dependencies = [ [[package]] name = "wasmtime-runtime" -version = "20.0.1" +version = "20.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d2b876c09b7863d8a01bf87eb45f3b121fab245f8afbff7c38c38c1c9059aee" +checksum = "65019d29d175c567b84173f2adf3b7a3af6d5592f8fe510dccae55d2569ec0d2" dependencies = [ "anyhow", "cc", @@ -2210,15 +2210,15 @@ dependencies = [ [[package]] name = "wasmtime-slab" -version = "20.0.1" +version = "20.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05c8ddfb8ebbab6ac186bc1f8c02ed988bc9ea455fea10f72bc3a07503309b4b" +checksum = "ca6585868f5c427c3e9d2a8c0c3354e6d7d4518a0d17723ab25a0c1eebf5d5b4" [[package]] name = "wasmtime-types" -version = "20.0.1" +version = "20.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fa3a1f3c0deb3034d76e7dcf340c5df670a6603019ee5b58adb70870649c769" +checksum = "84d5381ff174faded38c7b2085fbe430dff59489c87a91403354d710075750fb" dependencies = [ "cranelift-entity", "serde", @@ -2229,9 +2229,9 @@ dependencies = [ [[package]] name = "wasmtime-versioned-export-macros" -version = "20.0.1" +version = "20.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b85321f0a1cd3c859b94e728533ba00074d3eca62362acf6998be0eab6f4001c" +checksum = "0d3b70422fdfa915c903f003b8b42554a8ae1aa0c6208429d8314ebf5721f3ac" dependencies = [ "proc-macro2", "quote", @@ -2240,9 +2240,9 @@ dependencies = [ [[package]] name = "wasmtime-wasi" -version = "20.0.1" +version = "20.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c5966b1aa330f07ef58f83b074908ea210ee864948ae3697f8892c91104e6e3" +checksum = "08dd00241969c3be8c5dfdedbb8d9c5af6783e514ffbf8f7522036561bd1337a" dependencies = [ "anyhow", "async-trait", @@ -2271,9 +2271,9 @@ dependencies = [ [[package]] name = "wasmtime-winch" -version = "20.0.1" +version = "20.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e0d446696aa83f680d85e188670631cb7958957f63d027d6c36b945c2baa3e1e" +checksum = "996360967b5196dec20ddcfce499ce4dc80cc925c088b0f2b376d29b96833a6a" dependencies = [ "anyhow", "cranelift-codegen", @@ -2288,9 +2288,9 @@ dependencies = [ [[package]] name = "wasmtime-wit-bindgen" -version = "20.0.1" +version = "20.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d1d0c83af38eb6918af9c7cbc07d39f741a7baa9ddd152e19d9f93ff627dc05" +checksum = "01840c0cfbbb01664c796e3f4edbd656e58f9d76db083c7e7c6bba59ea657a96" dependencies = [ "anyhow", "heck 0.4.1", @@ -2354,9 +2354,9 @@ dependencies = [ [[package]] name = "wiggle" -version = "20.0.1" +version = "20.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "909dcda9e41ab1f8280cf7d774fa16d240792d6fe086a88ef69a9dd97827d289" +checksum = "f93fc3510978a905f931d74784ed8685bd6453e18ad8f92809e793d48827e3cd" dependencies = [ "anyhow", "async-trait", @@ -2369,9 +2369,9 @@ dependencies = [ [[package]] name = "wiggle-generate" -version = "20.0.1" +version = "20.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce431612cd480dbf925fb7c3c513dec176a57ea977bf3685726e4b0ab41a6408" +checksum = "4ec3909e70f36066526ad3b2abb4855ab836f8a6b293449582563ac50d651083" dependencies = [ "anyhow", "heck 0.4.1", @@ -2384,9 +2384,9 @@ dependencies = [ [[package]] name = "wiggle-macro" -version = "20.0.1" +version = "20.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9815f5f4b6c6e01449569469416783992ac703c8fbf83d3724dfb16a02fe2e5c" +checksum = "b4c31124572ab16401c491c0d4fb5fe5d17dab65fcfcc56d7d8efb1c1e56a3db" dependencies = [ "proc-macro2", "quote", @@ -2418,9 +2418,9 @@ checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" [[package]] name = "winch-codegen" -version = "0.18.1" +version = "0.18.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "720aabcf6838b31b42c7adc04d847696b066ddc5877efd6071ed5f08ae75bf20" +checksum = "cefeb84a0f39227cf2eb665cf348e6150ebf3372d08adff03264064ab590fdf4" dependencies = [ "anyhow", "cranelift-codegen", @@ -2669,18 +2669,18 @@ dependencies = [ [[package]] name = "zerocopy" -version = "0.7.33" +version = "0.7.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "087eca3c1eaf8c47b94d02790dd086cd594b912d2043d4de4bfdd466b3befb7c" +checksum = "ae87e3fcd617500e5d106f0380cf7b77f3c6092aae37191433159dda23cfb087" dependencies = [ "zerocopy-derive", ] [[package]] name = "zerocopy-derive" -version = "0.7.33" +version = "0.7.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f4b6c273f496d8fd4eaf18853e6b448760225dc030ff2c485a786859aea6393" +checksum = "15e934569e47891f7d9411f1a451d947a60e000ab3bd24fbb970f000387d1b3b" dependencies = [ "proc-macro2", "quote", diff --git a/Cargo.toml b/Cargo.toml index f33856e..cd7bb20 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -21,8 +21,8 @@ nom_locate = "4.2" rustyline = "14.0.0" tokio = { version = "1.36.0", features = ["macros"] } -wasmtime = { version = "20.0.1", features = ["component-model"] } -wasmtime-wasi = { version = "20.0.1" } +wasmtime = { version = "20.0.2", features = ["component-model"] } +wasmtime-wasi = { version = "20.0.2" } wit-component = "0.206.0" wit-parser = "0.206.0" wasm-compose = "0.206.0" From 8b8e9456218509f42f24c5ea28eb87cecc2a7024 Mon Sep 17 00:00:00 2001 From: Frank Rehwinkel Date: Tue, 7 May 2024 19:14:53 -0400 Subject: [PATCH 19/20] deps: update to wasm-tools crates 0.207.0 --- Cargo.lock | 56 +++++++++++++++++++++++++++--------------------------- Cargo.toml | 6 +++--- 2 files changed, 31 insertions(+), 31 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 44877fe..c1c8c3e 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1906,9 +1906,9 @@ checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" [[package]] name = "wasm-compose" -version = "0.206.0" +version = "0.207.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d6d4d4f62e79bd77583ea79cfeb243bbc978f29817b7c5f01c5b3b4a57607d27" +checksum = "ef991fbc1344f90e4742ea2f9f200fdefec5f4ff993e5b3573b6311825619ead" dependencies = [ "anyhow", "heck 0.4.1", @@ -1920,8 +1920,8 @@ dependencies = [ "serde_derive", "serde_yaml", "smallvec", - "wasm-encoder 0.206.0", - "wasmparser 0.206.0", + "wasm-encoder 0.207.0", + "wasmparser 0.207.0", "wat", ] @@ -1936,19 +1936,19 @@ dependencies = [ [[package]] name = "wasm-encoder" -version = "0.206.0" +version = "0.207.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d759312e1137f199096d80a70be685899cd7d3d09c572836bb2e9b69b4dc3b1e" +checksum = "d996306fb3aeaee0d9157adbe2f670df0236caf19f6728b221e92d0f27b3fe17" dependencies = [ "leb128", - "wasmparser 0.206.0", + "wasmparser 0.207.0", ] [[package]] name = "wasm-metadata" -version = "0.206.0" +version = "0.207.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84435ac34e29de6154fdb180ebbe2bdde96336f7ad0990003c43a21bd441303f" +checksum = "b2c44e62d325ce9253f88c01f0f67be121356767d12f2f13e701fdcd99e1f5b0" dependencies = [ "anyhow", "indexmap", @@ -1956,8 +1956,8 @@ dependencies = [ "serde_derive", "serde_json", "spdx", - "wasm-encoder 0.206.0", - "wasmparser 0.206.0", + "wasm-encoder 0.207.0", + "wasmparser 0.207.0", ] [[package]] @@ -1973,9 +1973,9 @@ dependencies = [ [[package]] name = "wasmparser" -version = "0.206.0" +version = "0.207.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39192edb55d55b41963db40fd49b0b542156f04447b5b512744a91d38567bdbc" +checksum = "e19bb9f8ab07616da582ef8adb24c54f1424c7ec876720b7da9db8ec0626c92c" dependencies = [ "ahash", "bitflags", @@ -2309,24 +2309,24 @@ dependencies = [ [[package]] name = "wast" -version = "206.0.0" +version = "207.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "68586953ee4960b1f5d84ebf26df3b628b17e6173bc088e0acfbce431469795a" +checksum = "0e40be9fd494bfa501309487d2dc0b3f229be6842464ecbdc54eac2679c84c93" dependencies = [ "bumpalo", "leb128", "memchr", "unicode-width", - "wasm-encoder 0.206.0", + "wasm-encoder 0.207.0", ] [[package]] name = "wat" -version = "1.206.0" +version = "1.207.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da4c6f2606276c6e991aebf441b2fc92c517807393f039992a3e0ad873efe4ad" +checksum = "8eb2b15e2d5f300f5e1209e7dc237f2549edbd4203655b6c6cab5cf180561ee7" dependencies = [ - "wast 206.0.0", + "wast 207.0.0", ] [[package]] @@ -2349,7 +2349,7 @@ dependencies = [ "wasmtime", "wasmtime-wasi", "wit-component", - "wit-parser 0.206.0", + "wit-parser 0.207.0", ] [[package]] @@ -2602,9 +2602,9 @@ dependencies = [ [[package]] name = "wit-component" -version = "0.206.0" +version = "0.207.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81e1ae4cace3706e29a8cf1f728b792255ecdc02653b9f4130ab6cc64f435a67" +checksum = "a411ff9c471737091b2c1a738a25031029fc4d0b8f1a60bef0e68906e9f6534b" dependencies = [ "anyhow", "bitflags", @@ -2613,10 +2613,10 @@ dependencies = [ "serde", "serde_derive", "serde_json", - "wasm-encoder 0.206.0", + "wasm-encoder 0.207.0", "wasm-metadata", - "wasmparser 0.206.0", - "wit-parser 0.206.0", + "wasmparser 0.207.0", + "wit-parser 0.207.0", ] [[package]] @@ -2639,9 +2639,9 @@ dependencies = [ [[package]] name = "wit-parser" -version = "0.206.0" +version = "0.207.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d226de4e95e052cb664d2bdad2f31d9cad5117038a3439568f078d1afd8842fe" +checksum = "78c83dab33a9618d86cfe3563cc864deffd08c17efc5db31a3b7cd1edeffe6e1" dependencies = [ "anyhow", "id-arena", @@ -2652,7 +2652,7 @@ dependencies = [ "serde_derive", "serde_json", "unicode-xid", - "wasmparser 0.206.0", + "wasmparser 0.207.0", ] [[package]] diff --git a/Cargo.toml b/Cargo.toml index cd7bb20..99e1cce 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -23,6 +23,6 @@ tokio = { version = "1.36.0", features = ["macros"] } wasmtime = { version = "20.0.2", features = ["component-model"] } wasmtime-wasi = { version = "20.0.2" } -wit-component = "0.206.0" -wit-parser = "0.206.0" -wasm-compose = "0.206.0" +wit-component = "0.207.0" +wit-parser = "0.207.0" +wasm-compose = "0.207.0" From 2ce6a4eabb769a446282fb7be989abad9ac3c967 Mon Sep 17 00:00:00 2001 From: Frank Rehwinkel Date: Tue, 7 May 2024 19:56:38 -0400 Subject: [PATCH 20/20] cargo fmt --- src/command.rs | 26 ++++++++++---------------- src/evaluator.rs | 24 ++++++++++++------------ src/runtime.rs | 34 ++++++++++++++-------------------- 3 files changed, 36 insertions(+), 48 deletions(-) diff --git a/src/command.rs b/src/command.rs index 26f962d..710557b 100644 --- a/src/command.rs +++ b/src/command.rs @@ -1,7 +1,7 @@ pub mod parser; mod tokenizer; -use std::collections::HashMap; use std::borrow::Cow; +use std::collections::HashMap; use anyhow::{bail, Context as _}; use colored::Colorize; @@ -351,13 +351,9 @@ fn format_val(val: &Val) -> String { format!("{{ {fields} }}") } Val::Tuple(t) => { - let items = t - .iter() - .map(format_val) - .collect::>() - .join(", "); + let items = t.iter().map(format_val).collect::>().join(", "); format!("({items})") - }, + } Val::Variant(..) => todo!(), Val::Enum(_) => todo!(), Val::Flags(_) => todo!(), @@ -380,11 +376,13 @@ fn val_as_type(val: &Val) -> Cow<'static, str> { Val::Float32(_) => "float32".into(), Val::Float64(_) => "float64".into(), Val::Char(_) => "char".into(), - Val::Option(t) => if let Some(t) = t { + Val::Option(t) => { + if let Some(t) = t { format!("option<{}>", val_as_type(t)).into() } else { "option".into() - }, + } + } Val::Result(r) => match r { Ok(Some(o)) => format!("Result>", val_as_type(o)).into(), Ok(None) => "Result".into(), @@ -392,7 +390,7 @@ fn val_as_type(val: &Val) -> Cow<'static, str> { Err(None) => "Result".into(), }, Val::List(t) => { - if ! t.is_empty() { + if !t.is_empty() { format!("list<{}>", val_as_type(&t[0])).into() } else { "list".into() @@ -407,13 +405,9 @@ fn val_as_type(val: &Val) -> Cow<'static, str> { format!("record{{ {field_types} }}").into() } Val::Tuple(t) => { - let item_types = t - .iter() - .map(val_as_type) - .collect::>() - .join(", "); + let item_types = t.iter().map(val_as_type).collect::>().join(", "); format!("tuple<{item_types}>").into() - }, + } Val::Variant(..) => "variant_specific".into(), Val::Enum(_) => "enum_type".into(), Val::Flags(_) => "flags".into(), diff --git a/src/evaluator.rs b/src/evaluator.rs index a40d767..4819a24 100644 --- a/src/evaluator.rs +++ b/src/evaluator.rs @@ -179,20 +179,21 @@ impl<'a> Evaluator<'a> { .sort_by(|(f1, _), (f2, _)| types.get(f1).unwrap().cmp(types.get(f2).unwrap())); for ((name, field_expr), field_type) in r.fields.into_iter().zip(ty.fields()) { - values.push((name.to_string(), self.eval(field_expr, Some(&field_type.ty))?)); + values.push(( + name.to_string(), + self.eval(field_expr, Some(&field_type.ty))?, + )); } Ok(Val::Record(values)) } parser::Literal::String(s) => { let val = Val::String(s.to_owned().into()); match type_hint { - Some(component::Type::Result(r)) => { - Ok(Val::Result( match (r.ok(), r.err()) { - (Some(_), _) => Ok(Some(Box::new(val))), - (_, Some(_)) => Err(Some(Box::new(val))), - (None, None) => return Ok(val), - })) - }, + Some(component::Type::Result(r)) => Ok(Val::Result(match (r.ok(), r.err()) { + (Some(_), _) => Ok(Some(Box::new(val))), + (_, Some(_)) => Err(Some(Box::new(val))), + (None, None) => return Ok(val), + })), _ => Ok(val), } } @@ -217,12 +218,11 @@ impl<'a> Evaluator<'a> { component::Type::Variant(_) => match self.lookup_in_scope(ident) { Ok(v) => Ok(v), Err(_) => Ok(Val::Variant(ident.to_string(), None)), - }, component::Type::Option(_) if ident == "none" => Ok(Val::Option(None)), - component::Type::Option(o) => { - Ok(Val::Option(Some(Box::new(self.resolve_ident(ident, Some(&o.ty()))?)))) - } + component::Type::Option(o) => Ok(Val::Option(Some(Box::new( + self.resolve_ident(ident, Some(&o.ty()))?, + )))), component::Type::Result(r) => Ok(Val::Result(match (r.ok(), r.err()) { (Some(o), _) => Ok(Some(Box::new(self.resolve_ident(ident, Some(&o))?))), (None, None) if ident == "ok" => Ok(None), diff --git a/src/runtime.rs b/src/runtime.rs index a33de56..9c0419f 100644 --- a/src/runtime.rs +++ b/src/runtime.rs @@ -49,12 +49,10 @@ impl Runtime { let stub_import = stub_import.clone(); match import { wit_parser::WorldItem::Function(f) => { - linker - .root() - .func_new(&f.name, move |_ctx, _args, _rets| { - stub_import(&import_name); - Ok(()) - })?; + linker.root().func_new(&f.name, move |_ctx, _args, _rets| { + stub_import(&import_name); + Ok(()) + })?; } wit_parser::WorldItem::Interface(i) => { let interface = resolver.interface_by_id(*i).unwrap(); @@ -237,15 +235,12 @@ impl Runtime { .func(&fun_name) .with_context(|| format!("no exported function named '{fun_name}' found"))? }; - import_instance.func_new( - &fun_name, - move |_ctx, args, results| { - let mut store = store.lock().unwrap(); - export_func.call(&mut *store, args, results)?; - export_func.post_return(&mut *store)?; - Ok(()) - }, - )?; + import_instance.func_new(&fun_name, move |_ctx, args, results| { + let mut store = store.lock().unwrap(); + export_func.call(&mut *store, args, results)?; + export_func.post_return(&mut *store)?; + Ok(()) + })?; } } self.refresh()?; @@ -309,15 +304,14 @@ impl Runtime { })?; } None => { - self.linker.root().func_new( - &name, - move |_ctx, args, results| { + self.linker + .root() + .func_new(&name, move |_ctx, args, results| { let mut store = store.lock().unwrap(); export_func.call(&mut *store, args, results)?; export_func.post_return(&mut *store)?; Ok(()) - }, - )?; + })?; } } self.refresh()?;