Unverified Commit 29a627ba authored by Benjamin Woodruff's avatar Benjamin Woodruff Committed by GitHub

chore(turbopack): Update indexmap dependency from 1.x to 2.x (#72429)

I noticed we were using a pretty old version of indexmap, this updates that.

`indexmap 1.9.3` still exists in the lockfile as there are some other dependencies we have (mostly `wasmer`) that pull it, but as those dependencies are updated, we'll get rid of it.

I specified the lower version range bound as `2.5.0` instead of `2.6.0` because I wanted to avoid introducing [yet another minor version of hashbrown](https://github.com/indexmap-rs/indexmap/blob/master/RELEASES.md), which might *slightly* help with compilation times. This is just a lower bound, so eventually we'll end up on `2.6.0` (or a later version) if dependency asks for it.

Closes PACK-3406
parent a59e5e70
...@@ -839,7 +839,7 @@ dependencies = [ ...@@ -839,7 +839,7 @@ dependencies = [
"ahash 0.8.11", "ahash 0.8.11",
"chrono", "chrono",
"either", "either",
"indexmap 2.2.6", "indexmap 2.5.0",
"itertools 0.13.0", "itertools 0.13.0",
"nom", "nom",
"once_cell", "once_cell",
...@@ -2550,7 +2550,7 @@ dependencies = [ ...@@ -2550,7 +2550,7 @@ dependencies = [
"futures-sink", "futures-sink",
"futures-util", "futures-util",
"http 0.2.11", "http 0.2.11",
"indexmap 2.2.6", "indexmap 2.5.0",
"slab", "slab",
"tokio", "tokio",
"tokio-util", "tokio-util",
...@@ -2997,9 +2997,9 @@ dependencies = [ ...@@ -2997,9 +2997,9 @@ dependencies = [
[[package]] [[package]]
name = "indexmap" name = "indexmap"
version = "2.2.6" version = "2.5.0"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" checksum = "68b900aa2f7301e21c36462b170ee99994de34dff39a4a6a528e80e7376d07e5"
dependencies = [ dependencies = [
"equivalent", "equivalent",
"hashbrown 0.14.5", "hashbrown 0.14.5",
...@@ -3966,7 +3966,7 @@ version = "0.1.0" ...@@ -3966,7 +3966,7 @@ version = "0.1.0"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"futures", "futures",
"indexmap 1.9.3", "indexmap 2.5.0",
"next-core", "next-core",
"regex", "regex",
"serde", "serde",
...@@ -4042,7 +4042,7 @@ dependencies = [ ...@@ -4042,7 +4042,7 @@ dependencies = [
"auto-hash-map", "auto-hash-map",
"base64 0.21.4", "base64 0.21.4",
"futures", "futures",
"indexmap 1.9.3", "indexmap 2.5.0",
"indoc", "indoc",
"lazy-regex", "lazy-regex",
"lazy_static", "lazy_static",
...@@ -4126,7 +4126,7 @@ dependencies = [ ...@@ -4126,7 +4126,7 @@ dependencies = [
"fxhash", "fxhash",
"getrandom", "getrandom",
"iana-time-zone", "iana-time-zone",
"indexmap 1.9.3", "indexmap 2.5.0",
"lightningcss-napi", "lightningcss-napi",
"mdxjs", "mdxjs",
"napi", "napi",
...@@ -5801,7 +5801,7 @@ version = "1.0.117" ...@@ -5801,7 +5801,7 @@ version = "1.0.117"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3" checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3"
dependencies = [ dependencies = [
"indexmap 2.2.6", "indexmap 2.5.0",
"itoa", "itoa",
"ryu", "ryu",
"serde", "serde",
...@@ -5913,7 +5913,7 @@ version = "0.9.34+deprecated" ...@@ -5913,7 +5913,7 @@ version = "0.9.34+deprecated"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "6a8b1a1a2ebf674015cc02edccce75287f1a0130d394307b36743c2f5d504b47" checksum = "6a8b1a1a2ebf674015cc02edccce75287f1a0130d394307b36743c2f5d504b47"
dependencies = [ dependencies = [
"indexmap 2.2.6", "indexmap 2.5.0",
"itoa", "itoa",
"ryu", "ryu",
"serde", "serde",
...@@ -6315,7 +6315,7 @@ dependencies = [ ...@@ -6315,7 +6315,7 @@ dependencies = [
"base64 0.21.4", "base64 0.21.4",
"dashmap 5.5.3", "dashmap 5.5.3",
"either", "either",
"indexmap 2.2.6", "indexmap 2.5.0",
"jsonc-parser", "jsonc-parser",
"lru", "lru",
"napi", "napi",
...@@ -6407,7 +6407,7 @@ dependencies = [ ...@@ -6407,7 +6407,7 @@ dependencies = [
"anyhow", "anyhow",
"crc", "crc",
"dashmap 5.5.3", "dashmap 5.5.3",
"indexmap 2.2.6", "indexmap 2.5.0",
"is-macro", "is-macro",
"once_cell", "once_cell",
"parking_lot", "parking_lot",
...@@ -6512,7 +6512,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" ...@@ -6512,7 +6512,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4aa30931f9b26af8edcb4cce605909d15dcfd7577220b22c50a2988f2a53c4c1" checksum = "4aa30931f9b26af8edcb4cce605909d15dcfd7577220b22c50a2988f2a53c4c1"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"indexmap 2.2.6", "indexmap 2.5.0",
"serde", "serde",
"serde_json", "serde_json",
"sourcemap", "sourcemap",
...@@ -6811,7 +6811,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" ...@@ -6811,7 +6811,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "27be5007d501b111706bb5e055a57388aeda89b5b13613831a285e4571575400" checksum = "27be5007d501b111706bb5e055a57388aeda89b5b13613831a285e4571575400"
dependencies = [ dependencies = [
"arrayvec 0.7.4", "arrayvec 0.7.4",
"indexmap 2.2.6", "indexmap 2.5.0",
"is-macro", "is-macro",
"rustc-hash 1.1.0", "rustc-hash 1.1.0",
"serde", "serde",
...@@ -7032,7 +7032,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" ...@@ -7032,7 +7032,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ba0fa4819b1353cbe5e15fabbc1618e0da6c51404214042457d3dd7a60e14960" checksum = "ba0fa4819b1353cbe5e15fabbc1618e0da6c51404214042457d3dd7a60e14960"
dependencies = [ dependencies = [
"arrayvec 0.7.4", "arrayvec 0.7.4",
"indexmap 2.2.6", "indexmap 2.5.0",
"num-bigint", "num-bigint",
"num_cpus", "num_cpus",
"once_cell", "once_cell",
...@@ -7091,7 +7091,7 @@ checksum = "536d242fcc9ae6dfcb3bf0fb1a0b087b20feca33e070aa51d585acbf8ac1ba5d" ...@@ -7091,7 +7091,7 @@ checksum = "536d242fcc9ae6dfcb3bf0fb1a0b087b20feca33e070aa51d585acbf8ac1ba5d"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"dashmap 5.5.3", "dashmap 5.5.3",
"indexmap 2.2.6", "indexmap 2.5.0",
"once_cell", "once_cell",
"preset_env_base", "preset_env_base",
"rustc-hash 1.1.0", "rustc-hash 1.1.0",
...@@ -7166,7 +7166,7 @@ checksum = "f0a2438f61a45819b5adf0c338c92c07d83306d630fb2e6dc261c60fb75653d7" ...@@ -7166,7 +7166,7 @@ checksum = "f0a2438f61a45819b5adf0c338c92c07d83306d630fb2e6dc261c60fb75653d7"
dependencies = [ dependencies = [
"better_scoped_tls", "better_scoped_tls",
"bitflags 2.5.0", "bitflags 2.5.0",
"indexmap 2.2.6", "indexmap 2.5.0",
"once_cell", "once_cell",
"phf", "phf",
"rayon", "rayon",
...@@ -7203,7 +7203,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" ...@@ -7203,7 +7203,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "09ca64973f33eb69cc29b9d1a432e6eebfbffa281be128318f8754013557a69e" checksum = "09ca64973f33eb69cc29b9d1a432e6eebfbffa281be128318f8754013557a69e"
dependencies = [ dependencies = [
"arrayvec 0.7.4", "arrayvec 0.7.4",
"indexmap 2.2.6", "indexmap 2.5.0",
"is-macro", "is-macro",
"num-bigint", "num-bigint",
"rayon", "rayon",
...@@ -7254,7 +7254,7 @@ dependencies = [ ...@@ -7254,7 +7254,7 @@ dependencies = [
"Inflector", "Inflector",
"anyhow", "anyhow",
"bitflags 2.5.0", "bitflags 2.5.0",
"indexmap 2.2.6", "indexmap 2.5.0",
"is-macro", "is-macro",
"path-clean 1.0.1", "path-clean 1.0.1",
"pathdiff", "pathdiff",
...@@ -7279,7 +7279,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" ...@@ -7279,7 +7279,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "f63d691ccea03a8eb25f37c7498e7609ad76ca3dc2070b630596e49f0b8fd1f4" checksum = "f63d691ccea03a8eb25f37c7498e7609ad76ca3dc2070b630596e49f0b8fd1f4"
dependencies = [ dependencies = [
"dashmap 5.5.3", "dashmap 5.5.3",
"indexmap 2.2.6", "indexmap 2.5.0",
"once_cell", "once_cell",
"petgraph", "petgraph",
"rayon", "rayon",
...@@ -7325,7 +7325,7 @@ checksum = "90002fdbe17f10c84cb29a102154a30ee5ad3e7165f0610d18ba8aa3a592924c" ...@@ -7325,7 +7325,7 @@ checksum = "90002fdbe17f10c84cb29a102154a30ee5ad3e7165f0610d18ba8aa3a592924c"
dependencies = [ dependencies = [
"base64 0.21.4", "base64 0.21.4",
"dashmap 5.5.3", "dashmap 5.5.3",
"indexmap 2.2.6", "indexmap 2.5.0",
"once_cell", "once_cell",
"rayon", "rayon",
"serde", "serde",
...@@ -7392,7 +7392,7 @@ version = "5.0.0" ...@@ -7392,7 +7392,7 @@ version = "5.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "89892c33cf84806957c34539cb84a26c69f6d2c7c8d9ae3131113105852f1d60" checksum = "89892c33cf84806957c34539cb84a26c69f6d2c7c8d9ae3131113105852f1d60"
dependencies = [ dependencies = [
"indexmap 2.2.6", "indexmap 2.5.0",
"rustc-hash 1.1.0", "rustc-hash 1.1.0",
"swc_atoms", "swc_atoms",
"swc_common", "swc_common",
...@@ -7409,7 +7409,7 @@ version = "5.0.0" ...@@ -7409,7 +7409,7 @@ version = "5.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "024a9ee9a19f448b31af002b90c43b9dfdb4e1fad23c76c21fe26a7c6e0f78a7" checksum = "024a9ee9a19f448b31af002b90c43b9dfdb4e1fad23c76c21fe26a7c6e0f78a7"
dependencies = [ dependencies = [
"indexmap 2.2.6", "indexmap 2.5.0",
"num_cpus", "num_cpus",
"once_cell", "once_cell",
"rayon", "rayon",
...@@ -7493,7 +7493,7 @@ version = "5.0.0" ...@@ -7493,7 +7493,7 @@ version = "5.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "3f65856acf41991a43d47d19ca947ee34f1152fccc42f048063c64eaf45a8e26" checksum = "3f65856acf41991a43d47d19ca947ee34f1152fccc42f048063c64eaf45a8e26"
dependencies = [ dependencies = [
"indexmap 2.2.6", "indexmap 2.5.0",
"petgraph", "petgraph",
"rustc-hash 1.1.0", "rustc-hash 1.1.0",
"swc_common", "swc_common",
...@@ -8113,7 +8113,7 @@ version = "0.19.15" ...@@ -8113,7 +8113,7 @@ version = "0.19.15"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "1b5bb770da30e5cbfde35a2d7b9b8a2c4b8ef89548a7a6aeab5c9a576e3e7421" checksum = "1b5bb770da30e5cbfde35a2d7b9b8a2c4b8ef89548a7a6aeab5c9a576e3e7421"
dependencies = [ dependencies = [
"indexmap 2.2.6", "indexmap 2.5.0",
"serde", "serde",
"serde_spanned", "serde_spanned",
"toml_datetime", "toml_datetime",
...@@ -8126,7 +8126,7 @@ version = "0.22.20" ...@@ -8126,7 +8126,7 @@ version = "0.22.20"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "583c44c02ad26b0c3f3066fe629275e50627026c51ac2e595cca4c230ce1ce1d" checksum = "583c44c02ad26b0c3f3066fe629275e50627026c51ac2e595cca4c230ce1ce1d"
dependencies = [ dependencies = [
"indexmap 2.2.6", "indexmap 2.5.0",
"serde", "serde",
"serde_spanned", "serde_spanned",
"toml_datetime", "toml_datetime",
...@@ -8423,7 +8423,7 @@ dependencies = [ ...@@ -8423,7 +8423,7 @@ dependencies = [
"erased-serde", "erased-serde",
"event-listener 2.5.3", "event-listener 2.5.3",
"futures", "futures",
"indexmap 1.9.3", "indexmap 2.5.0",
"mopa", "mopa",
"once_cell", "once_cell",
"parking_lot", "parking_lot",
...@@ -8458,7 +8458,7 @@ dependencies = [ ...@@ -8458,7 +8458,7 @@ dependencies = [
"dashmap 5.5.3", "dashmap 5.5.3",
"either", "either",
"hashbrown 0.14.5", "hashbrown 0.14.5",
"indexmap 1.9.3", "indexmap 2.5.0",
"lmdb-rkv", "lmdb-rkv",
"once_cell", "once_cell",
"parking_lot", "parking_lot",
...@@ -8514,7 +8514,7 @@ version = "0.1.0" ...@@ -8514,7 +8514,7 @@ version = "0.1.0"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"dotenvs", "dotenvs",
"indexmap 1.9.3", "indexmap 2.5.0",
"serde", "serde",
"turbo-tasks", "turbo-tasks",
"turbo-tasks-build", "turbo-tasks-build",
...@@ -8553,7 +8553,7 @@ dependencies = [ ...@@ -8553,7 +8553,7 @@ dependencies = [
"futures", "futures",
"futures-retry", "futures-retry",
"include_dir", "include_dir",
"indexmap 1.9.3", "indexmap 2.5.0",
"jsonc-parser", "jsonc-parser",
"mime", "mime",
"notify", "notify",
...@@ -8638,7 +8638,7 @@ dependencies = [ ...@@ -8638,7 +8638,7 @@ dependencies = [
"criterion", "criterion",
"dashmap 5.5.3", "dashmap 5.5.3",
"either", "either",
"indexmap 1.9.3", "indexmap 2.5.0",
"loom", "loom",
"num_cpus", "num_cpus",
"once_cell", "once_cell",
...@@ -8681,7 +8681,7 @@ dependencies = [ ...@@ -8681,7 +8681,7 @@ dependencies = [
"criterion", "criterion",
"difference", "difference",
"futures", "futures",
"indexmap 1.9.3", "indexmap 2.5.0",
"lazy_static", "lazy_static",
"regex", "regex",
"rstest", "rstest",
...@@ -8738,7 +8738,7 @@ name = "turbopack-browser" ...@@ -8738,7 +8738,7 @@ name = "turbopack-browser"
version = "0.1.0" version = "0.1.0"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"indexmap 1.9.3", "indexmap 2.5.0",
"indoc", "indoc",
"serde", "serde",
"serde_json", "serde_json",
...@@ -8819,7 +8819,7 @@ dependencies = [ ...@@ -8819,7 +8819,7 @@ dependencies = [
"auto-hash-map", "auto-hash-map",
"browserslist-rs", "browserslist-rs",
"futures", "futures",
"indexmap 1.9.3", "indexmap 2.5.0",
"lazy_static", "lazy_static",
"once_cell", "once_cell",
"patricia_tree", "patricia_tree",
...@@ -8857,7 +8857,7 @@ name = "turbopack-css" ...@@ -8857,7 +8857,7 @@ name = "turbopack-css"
version = "0.1.0" version = "0.1.0"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"indexmap 1.9.3", "indexmap 2.5.0",
"indoc", "indoc",
"lightningcss", "lightningcss",
"once_cell", "once_cell",
...@@ -8888,7 +8888,7 @@ dependencies = [ ...@@ -8888,7 +8888,7 @@ dependencies = [
"futures", "futures",
"hyper", "hyper",
"hyper-tungstenite", "hyper-tungstenite",
"indexmap 1.9.3", "indexmap 2.5.0",
"mime", "mime",
"mime_guess", "mime_guess",
"parking_lot", "parking_lot",
...@@ -8921,7 +8921,7 @@ dependencies = [ ...@@ -8921,7 +8921,7 @@ dependencies = [
"async-trait", "async-trait",
"criterion", "criterion",
"either", "either",
"indexmap 1.9.3", "indexmap 2.5.0",
"indoc", "indoc",
"lazy_static", "lazy_static",
"num-bigint", "num-bigint",
...@@ -8967,7 +8967,7 @@ version = "0.1.0" ...@@ -8967,7 +8967,7 @@ version = "0.1.0"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"async-trait", "async-trait",
"indexmap 1.9.3", "indexmap 2.5.0",
"lightningcss", "lightningcss",
"modularize_imports", "modularize_imports",
"serde", "serde",
...@@ -9005,7 +9005,7 @@ name = "turbopack-env" ...@@ -9005,7 +9005,7 @@ name = "turbopack-env"
version = "0.1.0" version = "0.1.0"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"indexmap 1.9.3", "indexmap 2.5.0",
"serde", "serde",
"turbo-tasks", "turbo-tasks",
"turbo-tasks-build", "turbo-tasks-build",
...@@ -9073,7 +9073,7 @@ dependencies = [ ...@@ -9073,7 +9073,7 @@ dependencies = [
"either", "either",
"futures", "futures",
"futures-retry", "futures-retry",
"indexmap 1.9.3", "indexmap 2.5.0",
"indoc", "indoc",
"mime", "mime",
"once_cell", "once_cell",
...@@ -9102,7 +9102,7 @@ name = "turbopack-nodejs" ...@@ -9102,7 +9102,7 @@ name = "turbopack-nodejs"
version = "0.1.0" version = "0.1.0"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"indexmap 1.9.3", "indexmap 2.5.0",
"indoc", "indoc",
"serde", "serde",
"tracing", "tracing",
...@@ -9121,7 +9121,7 @@ name = "turbopack-resolve" ...@@ -9121,7 +9121,7 @@ name = "turbopack-resolve"
version = "0.1.0" version = "0.1.0"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"indexmap 1.9.3", "indexmap 2.5.0",
"lazy_static", "lazy_static",
"regex", "regex",
"serde", "serde",
...@@ -9182,7 +9182,7 @@ dependencies = [ ...@@ -9182,7 +9182,7 @@ dependencies = [
"anyhow", "anyhow",
"dunce", "dunce",
"futures", "futures",
"indexmap 1.9.3", "indexmap 2.5.0",
"once_cell", "once_cell",
"serde", "serde",
"serde_json", "serde_json",
...@@ -9214,7 +9214,7 @@ dependencies = [ ...@@ -9214,7 +9214,7 @@ dependencies = [
"anyhow", "anyhow",
"either", "either",
"flate2", "flate2",
"indexmap 1.9.3", "indexmap 2.5.0",
"itertools 0.10.5", "itertools 0.10.5",
"postcard", "postcard",
"rayon", "rayon",
...@@ -9247,7 +9247,7 @@ name = "turbopack-wasm" ...@@ -9247,7 +9247,7 @@ name = "turbopack-wasm"
version = "0.1.0" version = "0.1.0"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"indexmap 1.9.3", "indexmap 2.5.0",
"indoc", "indoc",
"serde", "serde",
"turbo-tasks", "turbo-tasks",
...@@ -9943,7 +9943,7 @@ dependencies = [ ...@@ -9943,7 +9943,7 @@ dependencies = [
"ciborium", "ciborium",
"derive_builder 0.12.0", "derive_builder 0.12.0",
"hex", "hex",
"indexmap 2.2.6", "indexmap 2.5.0",
"schemars", "schemars",
"semver 1.0.23", "semver 1.0.23",
"serde", "serde",
...@@ -10143,7 +10143,7 @@ version = "0.110.0" ...@@ -10143,7 +10143,7 @@ version = "0.110.0"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "1dfcdb72d96f01e6c85b6bf20102e7423bdbaad5c337301bab2bbf253d26413c" checksum = "1dfcdb72d96f01e6c85b6bf20102e7423bdbaad5c337301bab2bbf253d26413c"
dependencies = [ dependencies = [
"indexmap 2.2.6", "indexmap 2.5.0",
"semver 1.0.23", "semver 1.0.23",
] ]
...@@ -10154,7 +10154,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" ...@@ -10154,7 +10154,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9dbe55c8f9d0dbd25d9447a5a889ff90c0cc3feaa7395310d3d826b2c703eaab" checksum = "9dbe55c8f9d0dbd25d9447a5a889ff90c0cc3feaa7395310d3d826b2c703eaab"
dependencies = [ dependencies = [
"bitflags 2.5.0", "bitflags 2.5.0",
"indexmap 2.2.6", "indexmap 2.5.0",
"semver 1.0.23", "semver 1.0.23",
] ]
...@@ -10724,7 +10724,7 @@ dependencies = [ ...@@ -10724,7 +10724,7 @@ dependencies = [
"cargo-lock", "cargo-lock",
"chrono", "chrono",
"clap 4.5.2", "clap 4.5.2",
"indexmap 1.9.3", "indexmap 2.5.0",
"inquire", "inquire",
"num-format", "num-format",
"owo-colors 3.5.0", "owo-colors 3.5.0",
......
...@@ -147,7 +147,7 @@ futures-retry = "0.6.0" ...@@ -147,7 +147,7 @@ futures-retry = "0.6.0"
hashbrown = "0.14.5" hashbrown = "0.14.5"
httpmock = { version = "0.6.8", default-features = false } httpmock = { version = "0.6.8", default-features = false }
image = { version = "0.25.0", default-features = false } image = { version = "0.25.0", default-features = false }
indexmap = "1.9.2" indexmap = "2.5.0"
indicatif = "0.17.3" indicatif = "0.17.3"
indoc = "2.0.0" indoc = "2.0.0"
itertools = "0.10.5" itertools = "0.10.5"
......
...@@ -135,7 +135,7 @@ impl VersionedContentMap { ...@@ -135,7 +135,7 @@ impl VersionedContentMap {
.get_mut(k) .get_mut(k)
// guaranteed // guaranteed
.unwrap() .unwrap()
.remove(&assets); .swap_remove(&assets);
changed = changed || res changed = changed || res
} }
changed changed
......
...@@ -104,7 +104,7 @@ pub(super) async fn update_chunk_list( ...@@ -104,7 +104,7 @@ pub(super) async fn update_chunk_list(
let mut chunks = FxIndexMap::<_, _>::default(); let mut chunks = FxIndexMap::<_, _>::default();
for (chunk_path, from_chunk_version) in &from.by_path { for (chunk_path, from_chunk_version) in &from.by_path {
if let Some(chunk_content) = by_path.remove(chunk_path) { if let Some(chunk_content) = by_path.swap_remove(chunk_path) {
let chunk_update = chunk_content let chunk_update = chunk_content
.update(TraitRef::cell(from_chunk_version.clone())) .update(TraitRef::cell(from_chunk_version.clone()))
.await?; .await?;
......
...@@ -195,7 +195,7 @@ pub(super) async fn update_ecmascript_merged_chunk( ...@@ -195,7 +195,7 @@ pub(super) async fn update_ecmascript_merged_chunk(
}; };
let chunk_update = if let Some(from_version) = let chunk_update = if let Some(from_version) =
from_versions_by_chunk_path.remove(chunk_path) from_versions_by_chunk_path.swap_remove(chunk_path)
{ {
// The chunk was present in the previous version, so we must update it. // The chunk was present in the previous version, so we must update it.
let update = update_ecmascript_chunk(*content, from_version).await?; let update = update_ecmascript_chunk(*content, from_version).await?;
......
...@@ -151,7 +151,7 @@ impl RouteTree { ...@@ -151,7 +151,7 @@ impl RouteTree {
self.not_found_sources self.not_found_sources
.extend(other.not_found_sources.iter().copied()); .extend(other.not_found_sources.iter().copied());
for (key, value) in other.static_segments.iter() { for (key, value) in other.static_segments.iter() {
if let Some((key, self_value)) = self.static_segments.remove_entry(key) { if let Some((key, self_value)) = self.static_segments.swap_remove_entry(key) {
static_segments.insert(key, vec![self_value, *value]); static_segments.insert(key, vec![self_value, *value]);
} else if let Some(list) = static_segments.get_mut(key) { } else if let Some(list) = static_segments.get_mut(key) {
list.push(*value); list.push(*value);
......
...@@ -342,7 +342,7 @@ impl DepGraph { ...@@ -342,7 +342,7 @@ impl DepGraph {
let data = data.get(id).unwrap(); let data = data.get(id).unwrap();
for var in data.var_decls.iter() { for var in data.var_decls.iter() {
required_vars.remove(var); required_vars.swap_remove(var);
} }
// Depend on import statements from 'ImportBinding' // Depend on import statements from 'ImportBinding'
...@@ -462,7 +462,7 @@ impl DepGraph { ...@@ -462,7 +462,7 @@ impl DepGraph {
is_type_only: false, is_type_only: false,
}); });
required_vars.remove(export); required_vars.swap_remove(export);
deps.push(PartId::Export(export.0.as_str().into())); deps.push(PartId::Export(export.0.as_str().into()));
...@@ -944,7 +944,7 @@ impl DepGraph { ...@@ -944,7 +944,7 @@ impl DepGraph {
&top_level_vars, &top_level_vars,
) )
}; };
used_ids.read.remove(&default_var.to_id()); used_ids.read.swap_remove(&default_var.to_id());
used_ids.write.insert(default_var.to_id()); used_ids.write.insert(default_var.to_id());
let mut captured_ids = if export.decl.is_fn_expr() { let mut captured_ids = if export.decl.is_fn_expr() {
ids_captured_by( ids_captured_by(
...@@ -956,7 +956,7 @@ impl DepGraph { ...@@ -956,7 +956,7 @@ impl DepGraph {
} else { } else {
Vars::default() Vars::default()
}; };
captured_ids.read.remove(&default_var.to_id()); captured_ids.read.swap_remove(&default_var.to_id());
let data = ItemData { let data = ItemData {
read_vars: used_ids.read, read_vars: used_ids.read,
......
...@@ -182,11 +182,11 @@ impl TurbopackFormat { ...@@ -182,11 +182,11 @@ impl TurbopackFormat {
}; };
let mut values = values.into_iter().collect::<FxIndexMap<_, _>>(); let mut values = values.into_iter().collect::<FxIndexMap<_, _>>();
let duration = values let duration = values
.remove("duration") .swap_remove("duration")
.and_then(|v| v.as_u64()) .and_then(|v| v.as_u64())
.unwrap_or(0); .unwrap_or(0);
let name = values let name = values
.remove("name") .swap_remove("name")
.and_then(|v| v.as_str().map(|s| s.to_string())) .and_then(|v| v.as_str().map(|s| s.to_string()))
.unwrap_or("event".into()); .unwrap_or("event".into());
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment