From 144fbabf5549903c3e4d166fff4a7ae4a1e7aae2 Mon Sep 17 00:00:00 2001 From: Joshua Wong Date: Tue, 28 Nov 2023 01:13:27 -0600 Subject: [PATCH] chore: bump swc version --- Cargo.lock | 964 +++++++++++++---------- Cargo.toml | 3 +- crates/forge_analyzer/src/definitions.rs | 55 +- crates/forge_analyzer/src/exports.rs | 9 +- 4 files changed, 569 insertions(+), 462 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index d744f974..279217d0 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -33,10 +33,23 @@ version = "0.7.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fcb51a0695d8f838b1ee009b3fbf66bda078cd64590202a864a8f3e8c4315c47" dependencies = [ + "getrandom", + "once_cell", + "version_check", +] + +[[package]] +name = "ahash" +version = "0.8.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91429305e9f0a25f6205c5b8e0d2db09e0708a7a6df0f42212bb56c32c8ac97a" +dependencies = [ + "cfg-if", "getrandom", "once_cell", "serde", "version_check", + "zerocopy", ] [[package]] @@ -107,28 +120,27 @@ dependencies = [ [[package]] name = "anyhow" -version = "1.0.68" +version = "1.0.75" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2cb2f989d18dd141ab8ae82f64d1a8cdd37e0840f73a406896cf5e99502fab61" +checksum = "a4668cab20f66d8d020e1fbc0ebe47217433c1b6c8f2040faf858554e394ace6" [[package]] name = "arrayvec" -version = "0.7.2" +version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8da52d66c7071e2e3fa2a1e5c6d088fec47b593032b254f5e980de8ea54454d6" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "ast_node" -version = "0.8.6" +version = "0.9.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf94863c5fdfee166d0907c44e5fee970123b2b7307046d35d1e671aa93afbba" +checksum = "c09c69dffe06d222d072c878c3afe86eee2179806f20503faec97250268b4c24" dependencies = [ - "darling", "pmutil", "proc-macro2", "quote", "swc_macros_common", - "syn 1.0.107", + "syn 2.0.32", ] [[package]] @@ -144,9 +156,9 @@ dependencies = [ [[package]] name = "auto_impl" -version = "0.5.0" +version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7862e21c893d65a1650125d157eaeec691439379a1cee17ee49031b79236ada4" +checksum = "fee3da8ef1276b0bee5dd1c7258010d8fffd31801447323115a25560e1327b89" dependencies = [ "proc-macro-error", "proc-macro2", @@ -189,9 +201,9 @@ checksum = "604178f6c5c21f02dc555784810edfb88d34ac2c73b2eae109655649ee73ce3d" [[package]] name = "better_scoped_tls" -version = "0.1.0" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b73e8ecdec39e98aa3b19e8cd0b8ed8f77ccb86a6b0b2dc7cd86d105438a2123" +checksum = "794edcc9b3fb07bb4aecaa11f093fd45663b4feadb782d68303a2268bc2701de" dependencies = [ "scoped-tls", ] @@ -219,26 +231,23 @@ dependencies = [ [[package]] name = "browserslist-rs" -version = "0.12.3" +version = "0.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef956561c9a03c35af46714efd0c135e21768a2a012f900ca8a59b28e75d0cd1" +checksum = "e33066f72a558361eeb1077b0aff0f1dce1ac75bdc20b38a642f155f767b2824" dependencies = [ - "ahash", + "ahash 0.8.6", "anyhow", "chrono", "either", "itertools 0.10.5", - "js-sys", "nom", "once_cell", "quote", "serde", - "serde-wasm-bindgen", "serde_json", "string_cache", "string_cache_codegen", "thiserror", - "wasm-bindgen", ] [[package]] @@ -266,11 +275,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "16b0a3d9ed01224b22057780a37bb8c5dbfe1be8ba48678e7bf57ec4b385411f" dependencies = [ "iana-time-zone", - "js-sys", "num-integer", "num-traits", "time 0.1.45", - "wasm-bindgen", "winapi", ] @@ -306,7 +313,7 @@ dependencies = [ "heck", "proc-macro2", "quote", - "syn 2.0.28", + "syn 2.0.32", ] [[package]] @@ -355,16 +362,6 @@ dependencies = [ "cfg-if", ] -[[package]] -name = "crossbeam-channel" -version = "0.5.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c2dd04ddaf88237dc3b8d8f9a3c1004b506b54b3313403944054d23c0870c521" -dependencies = [ - "cfg-if", - "crossbeam-utils", -] - [[package]] name = "crossbeam-deque" version = "0.8.2" @@ -452,41 +449,6 @@ dependencies = [ "syn 1.0.107", ] -[[package]] -name = "darling" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a01d95850c592940db9b8194bc39f4bc0e89dee5c4265e4b1807c34a9aba453c" -dependencies = [ - "darling_core", - "darling_macro", -] - -[[package]] -name = "darling_core" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "859d65a907b6852c9361e3185c862aae7fafd2887876799fa55f5f99dc40d610" -dependencies = [ - "fnv", - "ident_case", - "proc-macro2", - "quote", - "strsim", - "syn 1.0.107", -] - -[[package]] -name = "darling_macro" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c972679f83bdf9c42bd905396b6c3588a843a17f0f16dfcfa3e2c5d57441835" -dependencies = [ - "darling_core", - "quote", - "syn 1.0.107", -] - [[package]] name = "dashmap" version = "5.4.0" @@ -541,38 +503,6 @@ dependencies = [ "cfg-if", ] -[[package]] -name = "enum-iterator" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91a4ec26efacf4aeff80887a175a419493cb6f8b5480d26387eb0bd038976187" -dependencies = [ - "enum-iterator-derive", -] - -[[package]] -name = "enum-iterator-derive" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "828de45d0ca18782232dfb8f3ea9cc428e8ced380eb26a520baaacfc70de39ce" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.107", -] - -[[package]] -name = "enum_kind" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78b940da354ae81ef0926c5eaa428207b8f4f091d3956c891dfbd124162bed99" -dependencies = [ - "pmutil", - "proc-macro2", - "swc_macros_common", - "syn 1.0.107", -] - [[package]] name = "equivalent" version = "1.0.1" @@ -605,12 +535,6 @@ dependencies = [ "miniz_oxide 0.7.1", ] -[[package]] -name = "fnv" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" - [[package]] name = "forge_analyzer" version = "0.1.0" @@ -675,23 +599,23 @@ dependencies = [ [[package]] name = "form_urlencoded" -version = "1.1.0" +version = "1.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9c384f161156f5260c24a097c56119f9be8c798586aecc13afbcbe7b7e26bf8" +checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" dependencies = [ "percent-encoding", ] [[package]] name = "from_variant" -version = "0.1.4" +version = "0.1.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0981e470d2ab9f643df3921d54f1952ea100c39fdb6a3fdc820e20d2291df6c" +checksum = "03ec5dc38ee19078d84a692b1c41181ff9f94331c76cee66ff0208c770b5e54f" dependencies = [ "pmutil", "proc-macro2", "swc_macros_common", - "syn 1.0.107", + "syn 2.0.32", ] [[package]] @@ -735,18 +659,6 @@ dependencies = [ "wasi 0.11.0+wasi-snapshot-preview1", ] -[[package]] -name = "getset" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e45727250e75cc04ff2846a66397da8ef2b3db8e40e0cef4df67950a07621eb9" -dependencies = [ - "proc-macro-error", - "proc-macro2", - "quote", - "syn 1.0.107", -] - [[package]] name = "gimli" version = "0.27.0" @@ -759,7 +671,16 @@ version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" dependencies = [ - "ahash", + "ahash 0.7.6", +] + +[[package]] +name = "hashbrown" +version = "0.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "43a3c133739dddd0d2990f9a4bdf8eb4b21ef50e4851ca85ab661199821d510e" +dependencies = [ + "ahash 0.8.6", ] [[package]] @@ -792,6 +713,19 @@ dependencies = [ "libc", ] +[[package]] +name = "hstr" +version = "0.2.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "de90d3db62411eb62eddabe402d706ac4970f7ac8d088c05f11069cad9be9857" +dependencies = [ + "new_debug_unreachable", + "once_cell", + "phf", + "rustc-hash", + "smallvec", +] + [[package]] name = "iana-time-zone" version = "0.1.53" @@ -816,17 +750,11 @@ dependencies = [ "cxx-build", ] -[[package]] -name = "ident_case" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" - [[package]] name = "idna" -version = "0.3.0" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e14ddfc70884202db2244c223200c204c2bda1bc6e0998d11b5e024d657209e6" +checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" dependencies = [ "unicode-bidi", "unicode-normalization", @@ -840,9 +768,9 @@ checksum = "cb56e1aa765b4b4f3aadfab769793b7087bb03a4ea4920644a6d238e2df5b9ed" [[package]] name = "indexmap" -version = "1.9.2" +version = "1.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1885e79c1fc4b10f0e172c475f458b7f7b93061064d98c3293e98c5ba0c8b399" +checksum = "bd070e393353796e801d209ad339e89596eb4c8d430d18ede6a1cced8fafbd99" dependencies = [ "autocfg", "hashbrown 0.12.3", @@ -861,15 +789,15 @@ dependencies = [ [[package]] name = "is-macro" -version = "0.2.1" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c068d4c6b922cd6284c609cfa6dec0e41615c9c5a1a4ba729a970d8daba05fb" +checksum = "f4467ed1321b310c2625c5aa6c1b1ffc5de4d9e42668cf697a08fb033ee8265e" dependencies = [ "Inflector", "pmutil", "proc-macro2", "quote", - "syn 1.0.107", + "syn 2.0.32", ] [[package]] @@ -926,79 +854,6 @@ version = "1.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" -[[package]] -name = "lexical" -version = "6.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c7aefb36fd43fef7003334742cbf77b243fcd36418a1d1bdd480d613a67968f6" -dependencies = [ - "lexical-core", -] - -[[package]] -name = "lexical-core" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2cde5de06e8d4c2faabc400238f9ae1c74d5412d03a7bd067645ccbc47070e46" -dependencies = [ - "lexical-parse-float", - "lexical-parse-integer", - "lexical-util", - "lexical-write-float", - "lexical-write-integer", -] - -[[package]] -name = "lexical-parse-float" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "683b3a5ebd0130b8fb52ba0bdc718cc56815b6a097e28ae5a6997d0ad17dc05f" -dependencies = [ - "lexical-parse-integer", - "lexical-util", - "static_assertions", -] - -[[package]] -name = "lexical-parse-integer" -version = "0.8.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d0994485ed0c312f6d965766754ea177d07f9c00c9b82a5ee62ed5b47945ee9" -dependencies = [ - "lexical-util", - "static_assertions", -] - -[[package]] -name = "lexical-util" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5255b9ff16ff898710eb9eb63cb39248ea8a5bb036bea8085b1a767ff6c4e3fc" -dependencies = [ - "static_assertions", -] - -[[package]] -name = "lexical-write-float" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "accabaa1c4581f05a3923d1b4cfd124c329352288b7b9da09e766b0668116862" -dependencies = [ - "lexical-util", - "lexical-write-integer", - "static_assertions", -] - -[[package]] -name = "lexical-write-integer" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1b6f3d1f4422866b68192d62f77bc5c700bee84f3069f2469d7bc8c77852446" -dependencies = [ - "lexical-util", - "static_assertions", -] - [[package]] name = "libc" version = "0.2.150" @@ -1041,11 +896,11 @@ dependencies = [ [[package]] name = "lru" -version = "0.7.8" +version = "0.10.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e999beba7b6e8345721bd280141ed958096a2e4abdf74f67ff4ce49b4b54e47a" +checksum = "718e8fae447df0c7e1ba7f5189829e63fd536945c8988d61444c19039f16b670" dependencies = [ - "hashbrown 0.12.3", + "hashbrown 0.13.2", ] [[package]] @@ -1059,9 +914,9 @@ dependencies = [ [[package]] name = "memchr" -version = "2.5.0" +version = "2.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d" +checksum = "f665ee40bc4a3c5590afb1e9677db74a508659dfd71e126420da8274909a0167" [[package]] name = "memoffset" @@ -1263,9 +1118,9 @@ dependencies = [ [[package]] name = "once_cell" -version = "1.17.0" +version = "1.18.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f61fba1741ea2b3d6a1e3178721804bb716a68a6aeba1149b5d52e3d464ea66" +checksum = "dd8b5dd2ae5ed71462c540258bedcb51965123ad7e7ccf4b9a8cafaa4a63576d" [[package]] name = "overload" @@ -1316,9 +1171,9 @@ checksum = "8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44dd" [[package]] name = "percent-encoding" -version = "2.2.0" +version = "2.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "478c572c3d73181ff3c2539045f6eb99e5491218eae919370993b890cdbdd98e" +checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" [[package]] name = "petgraph" @@ -1327,18 +1182,17 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e6d5014253a1331579ce62aa67443b4a658c5e7dd03d4bc6d302b94474888143" dependencies = [ "fixedbitset", - "indexmap 1.9.2", + "indexmap 1.9.3", ] [[package]] name = "phf" -version = "0.10.1" +version = "0.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fabbf1ead8a5bcbc20f5f8b939ee3f5b0f6f281b6ad3468b84656b658b455259" +checksum = "ade2d8b8f33c7333b51bcf0428d37e217e9f32192ae4772156f65063b8ce03dc" dependencies = [ "phf_macros", - "phf_shared", - "proc-macro-hack", + "phf_shared 0.11.2", ] [[package]] @@ -1347,22 +1201,31 @@ version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5d5285893bb5eb82e6aaf5d59ee909a06a16737a8970984dd7746ba9283498d6" dependencies = [ - "phf_shared", + "phf_shared 0.10.0", + "rand", +] + +[[package]] +name = "phf_generator" +version = "0.11.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "48e4cc64c2ad9ebe670cb8fd69dd50ae301650392e81c05f9bfcb2d5bdbc24b0" +dependencies = [ + "phf_shared 0.11.2", "rand", ] [[package]] name = "phf_macros" -version = "0.10.0" +version = "0.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58fdf3184dd560f160dd73922bea2d5cd6e8f064bf4b13110abd81b03697b4e0" +checksum = "3444646e286606587e49f3bcf1679b8cef1dc2c5ecc29ddacaffc305180d464b" dependencies = [ - "phf_generator", - "phf_shared", - "proc-macro-hack", + "phf_generator 0.11.2", + "phf_shared 0.11.2", "proc-macro2", "quote", - "syn 1.0.107", + "syn 2.0.32", ] [[package]] @@ -1374,6 +1237,15 @@ dependencies = [ "siphasher", ] +[[package]] +name = "phf_shared" +version = "0.11.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90fcb95eef784c2ac79119d1dd819e162b5da872ce6f3c3abe1e8ca1c082f72b" +dependencies = [ + "siphasher", +] + [[package]] name = "pin-project-lite" version = "0.2.9" @@ -1382,13 +1254,13 @@ checksum = "e0a7ae3ac2f1173085d398531c705756c94a4c56843785df85a60c1a0afac116" [[package]] name = "pmutil" -version = "0.5.3" +version = "0.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3894e5d549cccbe44afecf72922f277f603cd4bb0219c8342631ef18fffbe004" +checksum = "52a40bc70c2c58040d2d8b167ba9a5ff59fc9dab7ad44771cfde3dcfde7a09c6" dependencies = [ "proc-macro2", "quote", - "syn 1.0.107", + "syn 2.0.32", ] [[package]] @@ -1411,17 +1283,17 @@ checksum = "925383efa346730478fb4838dbe9137d2a47675ad789c546d150a6e1dd4ab31c" [[package]] name = "preset_env_base" -version = "0.4.0" +version = "0.4.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db4a43af74678e784b17db952b7fd726937b0a058c7c972624ddfd366e7603e4" +checksum = "008ae5e91d877e168b73c17bed2e4dc7553cd7cc237a776d9479eab6642352c5" dependencies = [ - "ahash", + "ahash 0.8.6", "anyhow", "browserslist-rs", "dashmap", "from_variant", "once_cell", - "semver 1.0.16", + "semver 1.0.20", "serde", "st-map", "tracing", @@ -1461,12 +1333,6 @@ dependencies = [ "version_check", ] -[[package]] -name = "proc-macro-hack" -version = "0.5.20+deprecated" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc375e1527247fe1a97d8b7156678dfe7c1af2fc075c9a4db3690ecd2a148068" - [[package]] name = "proc-macro2" version = "1.0.66" @@ -1476,6 +1342,15 @@ dependencies = [ "unicode-ident", ] +[[package]] +name = "psm" +version = "0.1.21" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5787f7cda34e3033a72192c018bc5883100330f362ef279a8cbccfce8bb4e874" +dependencies = [ + "cc", +] + [[package]] name = "quote" version = "1.0.32" @@ -1523,9 +1398,9 @@ dependencies = [ [[package]] name = "rayon" -version = "1.6.1" +version = "1.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6db3a213adf02b3bcfd2d3846bb41cb22857d131789e01df434fb7e7bc0759b7" +checksum = "9c27db03db7734835b3f53954b534c91069375ce6ccaa2e065441e07d9b6cdb1" dependencies = [ "either", "rayon-core", @@ -1533,14 +1408,12 @@ dependencies = [ [[package]] name = "rayon-core" -version = "1.10.1" +version = "1.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cac410af5d00ab6884528b4ab69d1e8e146e8d471201800fa1b4524126de6ad3" +checksum = "5ce3fb6ad83f861aac485e76e1985cd109d9a3713802152be56c3b1f0e0658ed" dependencies = [ - "crossbeam-channel", "crossbeam-deque", "crossbeam-utils", - "num_cpus", ] [[package]] @@ -1578,12 +1451,6 @@ version = "0.6.28" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "456c603be3e8d448b072f410900c09faf164fbce2d480456f50eea6e25f9c848" -[[package]] -name = "retain_mut" -version = "0.1.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4389f1d5789befaf6029ebd9f7dac4af7f7e3d61b69d4f30e2ac02b57e7712b0" - [[package]] name = "ring" version = "0.16.20" @@ -1667,9 +1534,9 @@ dependencies = [ [[package]] name = "rustversion" -version = "1.0.11" +version = "1.0.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5583e89e108996506031660fe09baa5011b9dd0341b89029313006d1fb508d70" +checksum = "7ffc183a10b4478d04cbbbfc96d0873219d962dd5accaff2ffbd4ceb7df837f4" [[package]] name = "ryu" @@ -1677,6 +1544,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7b4b9743ed687d4b4bcedf9ff5eaa7398495ae14e61cba0a295704edbc7decde" +[[package]] +name = "ryu-js" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4950d85bc52415f8432144c97c4791bd0c4f7954de32a7270ee9cccd3c22b12b" + [[package]] name = "same-file" version = "1.0.6" @@ -1725,9 +1598,9 @@ dependencies = [ [[package]] name = "semver" -version = "1.0.16" +version = "1.0.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58bc9567378fc7690d6b2addae4e60ac2eeea07becb2c64b9f218b53865cba2a" +checksum = "836fa6a3e1e547f9a2c4040802ec865b5d85f4014efe00555d7090a3dcaa1090" dependencies = [ "serde", ] @@ -1747,17 +1620,6 @@ dependencies = [ "serde_derive", ] -[[package]] -name = "serde-wasm-bindgen" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3b4c031cd0d9014307d82b8abf653c0290fbdaeb4c02d00c63cf52f728628bf" -dependencies = [ - "js-sys", - "serde", - "wasm-bindgen", -] - [[package]] name = "serde_derive" version = "1.0.192" @@ -1766,7 +1628,7 @@ checksum = "d6c7207fbec9faa48073f3e3074cbe553af6ea512d7c21ba46e434e70ea9fbc1" dependencies = [ "proc-macro2", "quote", - "syn 2.0.28", + "syn 2.0.32", ] [[package]] @@ -1825,6 +1687,17 @@ version = "1.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +[[package]] +name = "smartstring" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3fb72c633efbaa2dd666986505016c32c3044395ceaf881518399d2f4127ee29" +dependencies = [ + "autocfg", + "static_assertions", + "version_check", +] + [[package]] name = "smawk" version = "0.3.1" @@ -1854,30 +1727,37 @@ checksum = "6e63cff320ae2c57904679ba7cb63280a3dc4613885beafb148ee7bf9aa9042d" [[package]] name = "st-map" -version = "0.1.6" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc9c9f3a1df5f73b7392bd9773108fef41ad9126f0282412fd5904389f0c0c4f" +checksum = "f352d5d14be5a1f956d76ae0c8060c3487aaa2a080f10a4b4ff023c7c05a9047" dependencies = [ "arrayvec", "static-map-macro", ] [[package]] -name = "stable_deref_trait" -version = "1.2.0" +name = "stacker" +version = "0.1.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3" +checksum = "c886bd4480155fd3ef527d45e9ac8dd7118a898a46530b7b94c3e21866259fce" +dependencies = [ + "cc", + "cfg-if", + "libc", + "psm", + "winapi", +] [[package]] name = "static-map-macro" -version = "0.2.3" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "752564de9cd8937fdbc1c55d47ac391758c352ab3755607cc391b659fe87d56b" +checksum = "7628ae0bd92555d3de4303da41a5c8b1c5363e892001325f34e4be9ed024d0d7" dependencies = [ "pmutil", "proc-macro2", "quote", - "syn 1.0.107", + "syn 2.0.32", ] [[package]] @@ -1895,7 +1775,7 @@ dependencies = [ "new_debug_unreachable", "once_cell", "parking_lot", - "phf_shared", + "phf_shared 0.10.0", "precomputed-hash", "serde", ] @@ -1906,23 +1786,23 @@ version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6bb30289b722be4ff74a408c3cc27edeaad656e06cb1fe8fa9231fa59c728988" dependencies = [ - "phf_generator", - "phf_shared", + "phf_generator 0.10.0", + "phf_shared 0.10.0", "proc-macro2", "quote", ] [[package]] name = "string_enum" -version = "0.3.2" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "994453cd270ad0265796eb24abf5540091ed03e681c5f3c12bc33e4db33253e1" +checksum = "8fa4d4f81d7c05b9161f8de839975d3326328b8ba2831164b465524cc2f55252" dependencies = [ "pmutil", "proc-macro2", "quote", "swc_macros_common", - "syn 1.0.107", + "syn 2.0.32", ] [[package]] @@ -1961,16 +1841,15 @@ dependencies = [ [[package]] name = "swc" -version = "0.239.1" +version = "0.269.73" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a68788142778ec4fb76367b7ae2883b6829763e139d2531a8dce17df63659242" +checksum = "a6f3f1bab39cd61b255c7d11a4e759ea8553ce17b56591ec5bb44d1c80787400" dependencies = [ - "ahash", "anyhow", "base64 0.13.1", "dashmap", "either", - "indexmap 1.9.2", + "indexmap 1.9.3", "jsonc-parser", "lru", "once_cell", @@ -1984,6 +1863,7 @@ dependencies = [ "swc_atoms", "swc_cached", "swc_common", + "swc_compiler_base", "swc_config", "swc_ecma_ast", "swc_ecma_codegen", @@ -2009,25 +1889,23 @@ dependencies = [ [[package]] name = "swc_atoms" -version = "0.4.33" +version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93a49e93996e1c1cfdb641cd94888da545d440ff6cada04155ef118adee620c1" +checksum = "b8a9e1b6d97f27b6abe5571f8fe3bdbd2fa987299fc2126450c7cde6214896ef" dependencies = [ + "hstr", "once_cell", "rustc-hash", "serde", - "string_cache", - "string_cache_codegen", - "triomphe", ] [[package]] name = "swc_cached" -version = "0.3.15" +version = "0.3.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9745d42d167cb60aeb1e85d2ee813ca455c3185bf7417f11fd102d745ae2b9e1" +checksum = "68b357b80879f6c4f4f34879d02eeae63aafc7730293e6eda3686f990d160486" dependencies = [ - "ahash", + "ahash 0.8.6", "anyhow", "dashmap", "once_cell", @@ -2037,11 +1915,11 @@ dependencies = [ [[package]] name = "swc_common" -version = "0.29.27" +version = "0.33.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90a2c285d33b47a5e532a662c178dc91956534ff52207892918d3034a534ae12" +checksum = "5ccb656cd57c93614e4e8b33a60e75ca095383565c1a8d2bbe6a1103942831e0" dependencies = [ - "ahash", + "ahash 0.8.6", "ast_node", "better_scoped_tls", "cfg-if", @@ -2055,7 +1933,6 @@ dependencies = [ "serde", "siphasher", "sourcemap", - "string_cache", "swc_atoms", "swc_eq_ignore_macros", "swc_visit", @@ -2064,13 +1941,35 @@ dependencies = [ "url", ] +[[package]] +name = "swc_compiler_base" +version = "0.3.77" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fdfb49fbaf555fe7e18afd26343f47cfe52b07a506d59b25fb85e4016c48d516" +dependencies = [ + "anyhow", + "base64 0.13.1", + "pathdiff", + "serde", + "sourcemap", + "swc_atoms", + "swc_common", + "swc_config", + "swc_ecma_ast", + "swc_ecma_codegen", + "swc_ecma_minifier", + "swc_ecma_parser", + "swc_ecma_visit", + "swc_timer", +] + [[package]] name = "swc_config" -version = "0.1.4" +version = "0.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4de36224eb9498fccd4e68971f0b83326ccf8592c2d424f257f3a1c76b2b211" +checksum = "9ba1c7a40d38f9dd4e9a046975d3faf95af42937b34b2b963be4d8f01239584b" dependencies = [ - "indexmap 1.9.2", + "indexmap 1.9.3", "serde", "serde_json", "swc_config_macro", @@ -2078,22 +1977,22 @@ dependencies = [ [[package]] name = "swc_config_macro" -version = "0.1.0" +version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb64bc03d90fd5c90d6ab917bb2b1d7fbd31957df39e31ea24a3f554b4372251" +checksum = "e5b5aaca9a0082be4515f0fbbecc191bf5829cd25b5b9c0a2810f6a2bb0d6829" dependencies = [ "pmutil", "proc-macro2", "quote", "swc_macros_common", - "syn 1.0.107", + "syn 2.0.32", ] [[package]] name = "swc_core" -version = "0.53.1" +version = "0.86.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b250fdfac2060ec6996c45939ff1ec295f78913738be9dcb6853fca88445a524" +checksum = "8faddb80e001ac29e7e99f65d20acb2bd58f8cd0c2728be796eaa77b5c5ebaa6" dependencies = [ "swc", "swc_atoms", @@ -2110,13 +2009,14 @@ dependencies = [ [[package]] name = "swc_ecma_ast" -version = "0.95.11" +version = "0.110.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81e5ff66d8aa3c21c32ffcdd871712f78a50819118690ba8195974d665d008b4" +checksum = "2c3d416121da2d56bcbd1b1623725a68890af4552fef0c6d1e4bfa92776ccd6a" dependencies = [ - "bitflags 1.3.2", + "bitflags 2.4.1", "is-macro", "num-bigint", + "phf", "scoped-tls", "serde", "string_enum", @@ -2127,9 +2027,9 @@ dependencies = [ [[package]] name = "swc_ecma_codegen" -version = "0.128.18" +version = "0.146.35" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ecb5143ce3b7089539fb55875a43b6111e4e1af1bb505e54c9cd4095ce12ab09" +checksum = "bfd3775ed7ccf01feaac61890d6fc50eefe21ace5b29667147f50e7c79701b32" dependencies = [ "memchr", "num-bigint", @@ -2146,22 +2046,216 @@ dependencies = [ [[package]] name = "swc_ecma_codegen_macros" -version = "0.7.1" +version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0159c99f81f52e48fe692ef7af1b0990b45d3006b14c6629be0b1ffee1b23aea" +checksum = "dcdff076dccca6cc6a0e0b2a2c8acfb066014382bc6df98ec99e755484814384" dependencies = [ "pmutil", "proc-macro2", "quote", "swc_macros_common", - "syn 1.0.107", + "syn 2.0.32", +] + +[[package]] +name = "swc_ecma_compat_bugfixes" +version = "0.1.47" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "263594aba60063b5fe54a62b7feb075f17897241d2fe38fd060cc7ce8b369c9b" +dependencies = [ + "swc_atoms", + "swc_common", + "swc_ecma_ast", + "swc_ecma_compat_es2015", + "swc_ecma_transforms_base", + "swc_ecma_utils", + "swc_ecma_visit", + "swc_trace_macro", + "tracing", +] + +[[package]] +name = "swc_ecma_compat_common" +version = "0.1.31" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5abed404c9425bf0d1f44da426f9fec6fe1833b696275ed4dff85550376a32d4" +dependencies = [ + "swc_common", + "swc_ecma_ast", + "swc_ecma_utils", + "swc_ecma_visit", + "swc_trace_macro", +] + +[[package]] +name = "swc_ecma_compat_es2015" +version = "0.1.47" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f62ff03e2d6cbd5e101af8d4d38692da849db6036b06f2ebbe24d0284e8bf906" +dependencies = [ + "arrayvec", + "indexmap 1.9.3", + "is-macro", + "serde", + "serde_derive", + "smallvec", + "swc_atoms", + "swc_common", + "swc_config", + "swc_ecma_ast", + "swc_ecma_compat_common", + "swc_ecma_transforms_base", + "swc_ecma_transforms_classes", + "swc_ecma_transforms_macros", + "swc_ecma_utils", + "swc_ecma_visit", + "swc_trace_macro", + "tracing", +] + +[[package]] +name = "swc_ecma_compat_es2016" +version = "0.1.45" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "43ef9881b31538c273ff79c31fbc45ea2e5c2e3cbbd93999565dad551d030c0a" +dependencies = [ + "swc_atoms", + "swc_common", + "swc_ecma_ast", + "swc_ecma_transforms_base", + "swc_ecma_transforms_macros", + "swc_ecma_utils", + "swc_ecma_visit", + "swc_trace_macro", + "tracing", +] + +[[package]] +name = "swc_ecma_compat_es2017" +version = "0.1.46" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "636edbfdf1986120e17876aed860553e4cbf6d75367b43be28959098ae564090" +dependencies = [ + "serde", + "swc_atoms", + "swc_common", + "swc_ecma_ast", + "swc_ecma_transforms_base", + "swc_ecma_transforms_macros", + "swc_ecma_utils", + "swc_ecma_visit", + "swc_trace_macro", + "tracing", +] + +[[package]] +name = "swc_ecma_compat_es2018" +version = "0.1.46" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85d32ff56a80fcbcec069eeeac489be1f2bc306bf3003b7d1dbdb86be3f98484" +dependencies = [ + "serde", + "swc_atoms", + "swc_common", + "swc_ecma_ast", + "swc_ecma_compat_common", + "swc_ecma_transforms_base", + "swc_ecma_transforms_macros", + "swc_ecma_utils", + "swc_ecma_visit", + "swc_trace_macro", + "tracing", +] + +[[package]] +name = "swc_ecma_compat_es2019" +version = "0.1.46" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7b2e8701265c4d7c5dcb7d93553b464477b2b517c935ab566ab3d682d530d6b2" +dependencies = [ + "swc_atoms", + "swc_common", + "swc_ecma_ast", + "swc_ecma_transforms_base", + "swc_ecma_utils", + "swc_ecma_visit", + "swc_trace_macro", + "tracing", +] + +[[package]] +name = "swc_ecma_compat_es2020" +version = "0.1.44" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "506289478d965d8d234e70b6b57d226cc050573eba67145f0f0071d214ad0147" +dependencies = [ + "serde", + "swc_atoms", + "swc_common", + "swc_ecma_ast", + "swc_ecma_compat_es2022", + "swc_ecma_transforms_base", + "swc_ecma_utils", + "swc_ecma_visit", + "swc_trace_macro", + "tracing", +] + +[[package]] +name = "swc_ecma_compat_es2021" +version = "0.1.44" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "34755368b408350d700e9eea0983e0c396602c0776ed3c340bf701f0f256f271" +dependencies = [ + "swc_atoms", + "swc_common", + "swc_ecma_ast", + "swc_ecma_transforms_base", + "swc_ecma_utils", + "swc_ecma_visit", + "swc_trace_macro", + "tracing", +] + +[[package]] +name = "swc_ecma_compat_es2022" +version = "0.1.45" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "33a3856e485682d9df95dd693a35f1d4b10faa2e9af1eb638f38ca92aadcf076" +dependencies = [ + "swc_atoms", + "swc_common", + "swc_ecma_ast", + "swc_ecma_compat_common", + "swc_ecma_transforms_base", + "swc_ecma_transforms_classes", + "swc_ecma_transforms_macros", + "swc_ecma_utils", + "swc_ecma_visit", + "swc_trace_macro", + "tracing", +] + +[[package]] +name = "swc_ecma_compat_es3" +version = "0.1.45" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "301a197861113095eb0e62201c4ea1e357691195b15fdc634188070ef3281ce0" +dependencies = [ + "swc_common", + "swc_ecma_ast", + "swc_ecma_transforms_base", + "swc_ecma_utils", + "swc_ecma_visit", + "swc_trace_macro", + "tracing", ] [[package]] name = "swc_ecma_ext_transforms" -version = "0.92.19" +version = "0.110.35" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f28c4cf9f3fb45067b0300a0d3020dde63f836d87ab4ca12485b37d7868f55d7" +checksum = "3cc0000e38d2c67772c632f3e0fe1d8c2a63479bcb9d2746b8042af6f65f42c7" dependencies = [ "phf", "swc_atoms", @@ -2173,11 +2267,10 @@ dependencies = [ [[package]] name = "swc_ecma_lints" -version = "0.67.24" +version = "0.89.45" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64de81f7e8a3af805797766aba92c410bc203f29816fd3d48d3394fe34445030" +checksum = "bc420c5cda6b25f2fe8823ab4ad7bd3437cdc50c74628b0027043dd7aea8cc8f" dependencies = [ - "ahash", "auto_impl", "dashmap", "parking_lot", @@ -2194,11 +2287,10 @@ dependencies = [ [[package]] name = "swc_ecma_loader" -version = "0.41.28" +version = "0.45.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f85e707c11871e45d103f81699189d8e94d06abf9b7dc958dcea8ff410762cd" +checksum = "31cf7549feec3698d0110a0a71ae547f31ae272dc92db3285ce126d6dcbdadf3" dependencies = [ - "ahash", "anyhow", "dashmap", "lru", @@ -2216,21 +2308,20 @@ dependencies = [ [[package]] name = "swc_ecma_minifier" -version = "0.160.38" +version = "0.189.71" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d446b81d163c76cc172366ae54cf26c841c67c776dc57e97d327842d6e27b87" +checksum = "860edb2c920b6737950256682d9e186b717edc849ab1a5529fa348be34afc438" dependencies = [ - "ahash", "arrayvec", - "indexmap 1.9.2", + "indexmap 1.9.3", "num-bigint", "num_cpus", "once_cell", "parking_lot", "radix_fmt", "regex", - "retain_mut", "rustc-hash", + "ryu-js", "serde", "serde_json", "swc_atoms", @@ -2251,16 +2342,19 @@ dependencies = [ [[package]] name = "swc_ecma_parser" -version = "0.123.16" +version = "0.141.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "928c148fee43281df26871a2d1f242092734622e70aa3ea7ad474723537c702d" +checksum = "0b8436a58ac9f31068e9bf871e2ce7f3a18fe1d7e3fe8d54abe4896673eae20c" dependencies = [ "either", - "enum_kind", - "lexical", + "new_debug_unreachable", "num-bigint", + "num-traits", + "phf", "serde", "smallvec", + "smartstring", + "stacker", "swc_atoms", "swc_common", "swc_ecma_ast", @@ -2270,17 +2364,17 @@ dependencies = [ [[package]] name = "swc_ecma_preset_env" -version = "0.176.6" +version = "0.203.59" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ebd54f36f15affcd628a192ef2ef9174e6cecc066036684d613cbc705e15425" +checksum = "f7aa97cb699e64e259db89d106d5fc1f982cd3cebc8a149dab479064b9b6544e" dependencies = [ - "ahash", "anyhow", "dashmap", - "indexmap 1.9.2", + "indexmap 1.9.3", "once_cell", "preset_env_base", - "semver 1.0.16", + "rustc-hash", + "semver 1.0.20", "serde", "serde_json", "st-map", @@ -2295,9 +2389,9 @@ dependencies = [ [[package]] name = "swc_ecma_transforms" -version = "0.199.27" +version = "0.226.59" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "947d24e05c1ab93c6e64d9534c41c91add3d40533e8ba4bd8504cf456dfcfe0f" +checksum = "cae6b1951361fd848ab55d0782563b8f88ab9502108b13937fed979adc0edf89" dependencies = [ "swc_atoms", "swc_common", @@ -2315,12 +2409,13 @@ dependencies = [ [[package]] name = "swc_ecma_transforms_base" -version = "0.112.24" +version = "0.134.46" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8136889c97ee3c8fd9409f836e30f01c97e1ee0ca01d74a887a1943e2a92d41f" +checksum = "dde2e2c69dc9d38cd594329c71f5cbcbcfd2ea2475cddacc8b5e60ffe4fc72e2" dependencies = [ "better_scoped_tls", - "bitflags 1.3.2", + "bitflags 2.4.1", + "indexmap 1.9.3", "once_cell", "phf", "rustc-hash", @@ -2337,9 +2432,9 @@ dependencies = [ [[package]] name = "swc_ecma_transforms_classes" -version = "0.101.24" +version = "0.123.47" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42225b4adf0400ca97852f42c521474d9960623732a7f687804913256936c1f2" +checksum = "bf77248c0126ef404e16bb578da9af89329680ee34b6aa2cd39c4f03f0207f2d" dependencies = [ "swc_atoms", "swc_common", @@ -2351,13 +2446,12 @@ dependencies = [ [[package]] name = "swc_ecma_transforms_compat" -version = "0.137.25" +version = "0.160.52" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c0c867a21058a6918b0e1ebd9f1ec2b3fd947de4ff71a3125c3f98f1cc40628e" +checksum = "15e244f72c6a725b779484967afe2dbc70fa4bc5659a74a81562737a5cb38381" dependencies = [ - "ahash", "arrayvec", - "indexmap 1.9.2", + "indexmap 1.9.3", "is-macro", "num-bigint", "serde", @@ -2366,6 +2460,17 @@ dependencies = [ "swc_common", "swc_config", "swc_ecma_ast", + "swc_ecma_compat_bugfixes", + "swc_ecma_compat_common", + "swc_ecma_compat_es2015", + "swc_ecma_compat_es2016", + "swc_ecma_compat_es2017", + "swc_ecma_compat_es2018", + "swc_ecma_compat_es2019", + "swc_ecma_compat_es2020", + "swc_ecma_compat_es2021", + "swc_ecma_compat_es2022", + "swc_ecma_compat_es3", "swc_ecma_transforms_base", "swc_ecma_transforms_classes", "swc_ecma_transforms_macros", @@ -2377,28 +2482,27 @@ dependencies = [ [[package]] name = "swc_ecma_transforms_macros" -version = "0.5.0" +version = "0.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ebf907935ec5492256b523ae7935a824d9fdc0368dcadc41375bad0dca91cd8b" +checksum = "8188eab297da773836ef5cf2af03ee5cca7a563e1be4b146f8141452c28cc690" dependencies = [ "pmutil", "proc-macro2", "quote", "swc_macros_common", - "syn 1.0.107", + "syn 2.0.32", ] [[package]] name = "swc_ecma_transforms_module" -version = "0.154.25" +version = "0.177.55" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5745e55266ffd7c14a392474e3a25885857c214bd45074b04c9a0c84a81509df" +checksum = "7b031ccdc24a608a77b5ad5ed82f9b8d8ee1a85200e9a8534d3aa8c12384104d" dependencies = [ "Inflector", - "ahash", "anyhow", - "bitflags 1.3.2", - "indexmap 1.9.2", + "bitflags 2.4.1", + "indexmap 1.9.3", "is-macro", "path-clean", "pathdiff", @@ -2418,13 +2522,12 @@ dependencies = [ [[package]] name = "swc_ecma_transforms_optimization" -version = "0.168.27" +version = "0.195.59" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "36cea8460fa0f28fea76afc4906a1f8848d9360dcbed181720b0e92a7f2e2a13" +checksum = "66edab303416a23ae8f9723e0265c4179b5fda114bcb4002a3664cc34f35ed50" dependencies = [ - "ahash", "dashmap", - "indexmap 1.9.2", + "indexmap 1.9.3", "once_cell", "petgraph", "rustc-hash", @@ -2443,11 +2546,12 @@ dependencies = [ [[package]] name = "swc_ecma_transforms_proposal" -version = "0.145.25" +version = "0.168.56" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8972e9b16e89917d99f669af270a41320a6ca08c3480eef075845414526ccc5e" +checksum = "1fcb12797536f9a41691994be4ff1927d5c1196a452a6bdd68af17cf135f0ee8" dependencies = [ "either", + "rustc-hash", "serde", "smallvec", "swc_atoms", @@ -2462,16 +2566,14 @@ dependencies = [ [[package]] name = "swc_ecma_transforms_react" -version = "0.156.26" +version = "0.180.57" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c3499f6c71eeb443a3cdcb0a82a8dcb70d83ce589f5be652fc0ff25ff68344b" +checksum = "685b914122d1af2ab348261f6aeec13693e4a2ed6af69a5a15af79bc496d4b03" dependencies = [ - "ahash", "base64 0.13.1", "dashmap", - "indexmap 1.9.2", + "indexmap 1.9.3", "once_cell", - "regex", "serde", "sha-1", "string_enum", @@ -2488,10 +2590,11 @@ dependencies = [ [[package]] name = "swc_ecma_transforms_typescript" -version = "0.160.27" +version = "0.185.57" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "86e08d5a9a6ecf206585753ff67052c9d936d2914f3683e8b0021204ef355b04" +checksum = "56f68de144cbc081f83b1994767133e2cf351e4452434376d7b7d9527c65cba9" dependencies = [ + "ryu-js", "serde", "swc_atoms", "swc_common", @@ -2504,12 +2607,11 @@ dependencies = [ [[package]] name = "swc_ecma_usage_analyzer" -version = "0.1.13" +version = "0.20.35" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95430933ea004dfa5d5da3cc383f57f578dedab27b8e4645c84610c6c72b3ab8" +checksum = "dfa8d5dc775d4bf35967a0216783058b13ffe5423b807927aa5dbc92251f6839" dependencies = [ - "ahash", - "indexmap 1.9.2", + "indexmap 1.9.3", "rustc-hash", "swc_atoms", "swc_common", @@ -2522,11 +2624,11 @@ dependencies = [ [[package]] name = "swc_ecma_utils" -version = "0.106.18" +version = "0.124.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6bdb27e68d2c658204efd98c506ea2ecf942737b513f5b2140b8d81d04fcedc1" +checksum = "ad013c92a6e05a850db088ae7a17dc667209780b2a1a313544540111f33b5233" dependencies = [ - "indexmap 1.9.2", + "indexmap 1.9.3", "num_cpus", "once_cell", "rustc-hash", @@ -2540,9 +2642,9 @@ dependencies = [ [[package]] name = "swc_ecma_visit" -version = "0.81.11" +version = "0.96.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aeee9de2cf4e80f0c6802f9a44989e6b1ad973b94849e76b1745f6d87144f517" +checksum = "ba962f0becf83bab12a17365dface5a4f636c9e1743d479e292b96910a753743" dependencies = [ "num-bigint", "swc_atoms", @@ -2554,21 +2656,21 @@ dependencies = [ [[package]] name = "swc_eq_ignore_macros" -version = "0.1.1" +version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c20468634668c2bbab581947bb8c75c97158d5a6959f4ba33df20983b20b4f6" +checksum = "05a95d367e228d52484c53336991fdcf47b6b553ef835d9159db4ba40efb0ee8" dependencies = [ "pmutil", "proc-macro2", "quote", - "syn 1.0.107", + "syn 2.0.32", ] [[package]] name = "swc_error_reporters" -version = "0.13.28" +version = "0.17.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad1b6b90dbfe7a4c7962c21732cc403f071bb795d93c5a82bce5290e31b3a9b5" +checksum = "d29add35412af288be50e1012bbb825a66871bb2b4d960d1c456917ec3ccea32" dependencies = [ "anyhow", "miette 4.7.1", @@ -2579,35 +2681,34 @@ dependencies = [ [[package]] name = "swc_fast_graph" -version = "0.17.28" +version = "0.21.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c54361a935915a14d68a906126a8ee6e08ac27a0698a74337cbd6c0e15af40a" +checksum = "8117f6d10bbcb30cb3e549d6fa7637cb6d7c713cb71b2ce1808105a6825c788d" dependencies = [ - "ahash", - "indexmap 1.9.2", + "indexmap 1.9.3", "petgraph", + "rustc-hash", "swc_common", ] [[package]] name = "swc_macros_common" -version = "0.3.6" +version = "0.3.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4be988307882648d9bc7c71a6a73322b7520ef0211e920489a98f8391d8caa2" +checksum = "7a273205ccb09b51fabe88c49f3b34c5a4631c4c00a16ae20e03111d6a42e832" dependencies = [ "pmutil", "proc-macro2", "quote", - "syn 1.0.107", + "syn 2.0.32", ] [[package]] name = "swc_node_comments" -version = "0.16.27" +version = "0.20.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7fda859d1a9e48fb151e9da8cfc29cac4dd788941ba9cf639a77828c978adcb7" +checksum = "282ef548f602694c4eaa36a1d704282fd9713b9725b58bce7fb41630feefc4f7" dependencies = [ - "ahash", "dashmap", "swc_atoms", "swc_common", @@ -2615,29 +2716,29 @@ dependencies = [ [[package]] name = "swc_timer" -version = "0.17.29" +version = "0.21.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e5e7e11a10d9900fc60809bf560ef7ebf0b571dc5b0733005fb11343270574b" +checksum = "5a200243f3c296f74f52a562342ec0e972376377f4c202b0fa84a0e860a3bff7" dependencies = [ "tracing", ] [[package]] name = "swc_trace_macro" -version = "0.1.2" +version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4795c8d23e0de62eef9cac0a20ae52429ee2ffc719768e838490f195b7d7267" +checksum = "ff9719b6085dd2824fd61938a881937be14b08f95e2d27c64c825a9f65e052ba" dependencies = [ "proc-macro2", "quote", - "syn 1.0.107", + "syn 2.0.32", ] [[package]] name = "swc_visit" -version = "0.5.3" +version = "0.5.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82f2bcb7223e185c4c7cbf5e0c1207dec6d2bfd5e72e3fb7b3e8d179747e9130" +checksum = "e87c337fbb2d191bf371173dea6a957f01899adb8f189c6c31b122a6cfc98fc3" dependencies = [ "either", "swc_visit_macros", @@ -2645,16 +2746,16 @@ dependencies = [ [[package]] name = "swc_visit_macros" -version = "0.5.4" +version = "0.5.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fb1f3561674d84947694d41fb6d5737d19539222779baeac1b3a071a2b29428" +checksum = "0f322730fb82f3930a450ac24de8c98523af7d34ab8cb2f46bcb405839891a99" dependencies = [ "Inflector", "pmutil", "proc-macro2", "quote", "swc_macros_common", - "syn 1.0.107", + "syn 2.0.32", ] [[package]] @@ -2670,9 +2771,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.28" +version = "2.0.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04361975b3f5e348b2189d8dc55bc942f278b2d482a6a0365de5bdd62d351567" +checksum = "239814284fd6f1a4ffe4ca893952cdd93c224b6a1571c9a9eadd670295c0c9e2" dependencies = [ "proc-macro2", "quote", @@ -2736,7 +2837,7 @@ checksum = "266b2e40bc00e5a6c09c3584011e08b06f123c00362c92b975ba9843aaaa14b8" dependencies = [ "proc-macro2", "quote", - "syn 2.0.28", + "syn 2.0.32", ] [[package]] @@ -2824,7 +2925,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.28", + "syn 2.0.32", ] [[package]] @@ -2878,16 +2979,6 @@ dependencies = [ "tracing-subscriber", ] -[[package]] -name = "triomphe" -version = "0.1.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1ee9bd9239c339d714d657fac840c6d2a4f9c45f4f9ec7b0975113458be78db" -dependencies = [ - "serde", - "stable_deref_trait", -] - [[package]] name = "typed-arena" version = "2.0.2" @@ -2908,9 +2999,9 @@ checksum = "497961ef93d974e23eb6f433eb5fe1b7930b659f06d12dec6fc44a8f554c0bba" [[package]] name = "unicode-bidi" -version = "0.3.8" +version = "0.3.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "099b7128301d285f79ddd55b9a83d5e6b9e97c92e0ea0daebee7263e932de992" +checksum = "92888ba5573ff080736b3648696b70cafad7d250551175acbaa4e0385b3e1460" [[package]] name = "unicode-id" @@ -2982,9 +3073,9 @@ dependencies = [ [[package]] name = "url" -version = "2.3.1" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d68c799ae75762b8c3fe375feb6600ef5602c883c5d21eb51c09f22b83c4643" +checksum = "31e6302e3bb753d46e83516cae55ae196fc0c309407cf11ab35cc51a4c2a4633" dependencies = [ "form_urlencoded", "idna", @@ -3005,17 +3096,12 @@ checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" [[package]] name = "vergen" -version = "7.5.0" +version = "8.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "571b69f690c855821462709b6f41d42ceccc316fbd17b60bd06d06928cfe6a99" +checksum = "1290fd64cc4e7d3c9b07d7f333ce0ce0007253e32870e632624835cc80b83939" dependencies = [ "anyhow", - "cfg-if", - "enum-iterator", - "getset", "rustversion", - "thiserror", - "time 0.3.30", ] [[package]] @@ -3279,3 +3365,23 @@ name = "yansi" version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "09041cd90cf85f7f8b2df60c646f853b7f535ce68f85244eb6731cf89fa498ec" + +[[package]] +name = "zerocopy" +version = "0.7.26" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e97e415490559a91254a2979b4829267a57d2fcd741a98eee8b722fb57289aa0" +dependencies = [ + "zerocopy-derive", +] + +[[package]] +name = "zerocopy-derive" +version = "0.7.26" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dd7e48ccf166952882ca8bd778a43502c64f33bf94c12ebe2a7f08e5a0f6689f" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.32", +] diff --git a/Cargo.toml b/Cargo.toml index def13455..1b6e40d5 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -24,8 +24,7 @@ once_cell = "1.17.0" regex = "1.7.1" rustc-hash = "1.1.0" smallvec = { version = "1.11.2", features = ["union", "const_new"] } -swc_core = { version = "0.53.1", features = [ - "common_perf", +swc_core = { version = "0.86.82", features = [ "common", "common_sourcemap", "ecma_visit_path", diff --git a/crates/forge_analyzer/src/definitions.rs b/crates/forge_analyzer/src/definitions.rs index 71a15ca4..f30ae608 100644 --- a/crates/forge_analyzer/src/definitions.rs +++ b/crates/forge_analyzer/src/definitions.rs @@ -16,8 +16,8 @@ use swc_core::{ CallExpr, Callee, ClassDecl, ClassExpr, ClassMethod, ComputedPropName, CondExpr, Constructor, ContinueStmt, Decl, DefaultDecl, DoWhileStmt, ExportAll, ExportDecl, ExportDefaultDecl, ExportDefaultExpr, ExportNamedSpecifier, Expr, ExprOrSpread, - ExprStmt, FnDecl, FnExpr, ForInStmt, ForOfStmt, ForStmt, Function, Id, Ident, IfStmt, - Import, ImportDecl, ImportDefaultSpecifier, ImportNamedSpecifier, + ExprStmt, FnDecl, FnExpr, ForHead, ForInStmt, ForOfStmt, ForStmt, Function, Id, Ident, + IfStmt, Import, ImportDecl, ImportDefaultSpecifier, ImportNamedSpecifier, ImportStarAsSpecifier, JSXAttrName, JSXAttrOrSpread, JSXAttrValue, JSXElement, JSXElementChild, JSXElementName, JSXExpr, JSXExprContainer, JSXFragment, JSXMemberExpr, JSXNamespacedName, JSXObject, JSXSpreadChild, JSXText, KeyValuePatProp, KeyValueProp, @@ -27,8 +27,8 @@ use swc_core::{ PropName, PropOrSpread, RestPat, ReturnStmt, SeqExpr, Stmt, Str, Super, SuperProp, SuperPropExpr, SwitchStmt, TaggedTpl, ThisExpr, ThrowStmt, Tpl, TplElement, TryStmt, TsAsExpr, TsConstAssertion, TsInstantiation, TsNonNullExpr, TsSatisfiesExpr, - TsTypeAssertion, UnaryExpr, UpdateExpr, VarDecl, VarDeclOrExpr, VarDeclOrPat, - VarDeclarator, WhileStmt, WithStmt, YieldExpr, + TsTypeAssertion, UnaryExpr, UpdateExpr, VarDecl, VarDeclOrExpr, VarDeclarator, + WhileStmt, WithStmt, YieldExpr, }, atoms::{Atom, JsWord}, visit::{noop_visit_type, Visit, VisitWith}, @@ -1036,7 +1036,7 @@ impl<'cx> FunctionAnalyzer<'cx> { if let [ExprOrSpread { expr, .. }] = args { debug!("found useState/then/map/foreach/filter"); match &**expr { - Expr::Arrow(ArrowExpr { body, .. }) => match body { + Expr::Arrow(ArrowExpr { body, .. }) => match &**body { BlockStmtOrExpr::BlockStmt(stmt) => { self.lower_stmts(&stmt.stmts); return Operand::UNDEF; @@ -1141,7 +1141,7 @@ impl<'cx> FunctionAnalyzer<'cx> { if ident_value.sym.starts_with("on") && second_char.is_uppercase() { match &**expr { Expr::Arrow(arrow_expr) => { - if let BlockStmtOrExpr::Expr(expr) = &arrow_expr.body { + if let BlockStmtOrExpr::Expr(expr) = &*arrow_expr.body { self.lower_expr(&**expr); } } @@ -1497,7 +1497,7 @@ impl<'cx> FunctionAnalyzer<'cx> { | Expr::TsInstantiation(TsInstantiation { expr, .. }) | Expr::TsSatisfies(TsSatisfiesExpr { expr, .. }) => self.lower_expr(expr), Expr::PrivateName(PrivateName { id, .. }) => todo!(), - Expr::OptChain(OptChainExpr { base, .. }) => match base { + Expr::OptChain(OptChainExpr { base, .. }) => match &**base { OptChainBase::Call(OptCall { callee, args, .. }) => { self.lower_call(callee.as_ref().into(), args) } @@ -1666,6 +1666,7 @@ impl<'cx> FunctionAnalyzer<'cx> { Decl::Var(var) => { self.lower_var_decl(var); } + Decl::Using(_) => {} Decl::TsInterface(_) | Decl::TsTypeAlias(_) | Decl::TsEnum(_) @@ -1678,12 +1679,15 @@ impl<'cx> FunctionAnalyzer<'cx> { } } - fn lower_loop(&mut self, left: &VarDeclOrPat, right: &Expr, body: &Stmt) { + fn lower_loop(&mut self, left: &ForHead, right: &Expr, body: &Stmt) { // FIXME: don't assume loops are infinite let opnd = self.lower_expr(right); match left { - VarDeclOrPat::VarDecl(var) => self.lower_var_decl(var), - VarDeclOrPat::Pat(pat) => self.bind_pats(pat, Rvalue::Read(opnd)), + ForHead::VarDecl(var) => self.lower_var_decl(&*var), + ForHead::Pat(pat) => self.bind_pats(pat, Rvalue::Read(opnd)), + ForHead::UsingDecl(_) => { + //FIXME: investigate this case + } } self.lower_stmt(body); } @@ -1786,7 +1790,11 @@ impl Visit for LocalDefiner<'_> { ident.visit_with(self); } Decl::Var(vars) => vars.visit_children_with(self), - Decl::TsInterface(_) | Decl::TsTypeAlias(_) | Decl::TsEnum(_) | Decl::TsModule(_) => {} + Decl::Using(_) + | Decl::TsInterface(_) + | Decl::TsTypeAlias(_) + | Decl::TsEnum(_) + | Decl::TsModule(_) => {} } } @@ -1965,7 +1973,7 @@ impl Visit for FunctionCollector<'_> { operand_stack: vec![], in_lhs: false, }; - match func_body { + match &**func_body { BlockStmtOrExpr::BlockStmt(BlockStmt { stmts, .. }) => { analyzer.lower_stmts(stmts); } @@ -2228,8 +2236,7 @@ impl Visit for Lowerer<'_> { let owner = self.res .add_anonymous("__CONSTRUCTOR", AnonType::Closure, self.curr_mod); - self.res - .add_class_method(&ident.sym, n.key.clone(), class_def, owner); + self.res.add_class_method(n.key.clone(), class_def, owner); } } } @@ -2243,8 +2250,7 @@ impl Visit for Lowerer<'_> { let owner = self.res .add_anonymous("__CLASSMETHOD", AnonType::Closure, self.curr_mod); - self.res - .add_class_method(&ident.sym, n.key.clone(), class_def, owner); + self.res.add_class_method(n.key.clone(), class_def, owner); } } } @@ -2588,10 +2594,11 @@ impl Visit for ExportCollector<'_> { let VarDecl { decls, .. } = &**vardecls; decls.iter().for_each(|var| self.visit_var_declarator(var)); } - Decl::TsInterface(_) => {} - Decl::TsTypeAlias(_) => {} - Decl::TsEnum(_) => {} - Decl::TsModule(_) => {} + Decl::Using(_) + | Decl::TsInterface(_) + | Decl::TsTypeAlias(_) + | Decl::TsEnum(_) + | Decl::TsModule(_) => {} }; } @@ -2782,13 +2789,7 @@ impl Environment { } } - fn add_class_method( - &mut self, - name: impl Into, - n: PropName, - class_def: DefId, - owner: DefId, - ) { + fn add_class_method(&mut self, n: PropName, class_def: DefId, owner: DefId) { if let DefKind::Class(class) = self.def_mut(class_def) { if let PropName::Ident(ident) = &n { class.pub_members.push((ident.sym.to_owned(), owner)); diff --git a/crates/forge_analyzer/src/exports.rs b/crates/forge_analyzer/src/exports.rs index da36c186..826bc46c 100644 --- a/crates/forge_analyzer/src/exports.rs +++ b/crates/forge_analyzer/src/exports.rs @@ -39,10 +39,11 @@ impl Visit for ExportCollector { let VarDecl { decls, .. } = &**vardecls; decls.iter().for_each(|var| self.visit_var_declarator(var)); } - Decl::TsInterface(_) => {} - Decl::TsTypeAlias(_) => {} - Decl::TsEnum(_) => {} - Decl::TsModule(_) => {} + Decl::Using(_) + | Decl::TsInterface(_) + | Decl::TsTypeAlias(_) + | Decl::TsEnum(_) + | Decl::TsModule(_) => {} }; }