diff --git a/Cargo.lock b/Cargo.lock index f2e99e77718..7ac2311c92b 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -215,7 +215,7 @@ dependencies = [ "chalk-ir", "ena", "indexmap 1.9.3", - "itertools", + "itertools 0.10.5", "petgraph", "rustc-hash", "tracing", @@ -497,7 +497,7 @@ dependencies = [ "hir-def", "hir-expand", "hir-ty", - "itertools", + "itertools 0.12.0", "once_cell", "profile", "rustc-hash", @@ -526,7 +526,7 @@ dependencies = [ "hir-expand", "indexmap 2.0.0", "intern", - "itertools", + "itertools 0.12.0", "la-arena 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", "limit", "mbe", @@ -554,7 +554,7 @@ dependencies = [ "expect-test", "hashbrown 0.12.3", "intern", - "itertools", + "itertools 0.12.0", "la-arena 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", "limit", "mbe", @@ -586,7 +586,7 @@ dependencies = [ "hir-def", "hir-expand", "intern", - "itertools", + "itertools 0.12.0", "la-arena 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", "limit", "nohash-hasher", @@ -633,7 +633,7 @@ dependencies = [ "ide-db", "ide-diagnostics", "ide-ssr", - "itertools", + "itertools 0.12.0", "nohash-hasher", "oorandom", "profile", @@ -659,7 +659,7 @@ dependencies = [ "expect-test", "hir", "ide-db", - "itertools", + "itertools 0.12.0", "profile", "smallvec", "sourcegen", @@ -678,7 +678,7 @@ dependencies = [ "expect-test", "hir", "ide-db", - "itertools", + "itertools 0.12.0", "once_cell", "profile", "smallvec", @@ -700,7 +700,7 @@ dependencies = [ "fst", "hir", "indexmap 2.0.0", - "itertools", + "itertools 0.12.0", "limit", "line-index 0.1.0-pre.1", "memchr", @@ -731,7 +731,7 @@ dependencies = [ "expect-test", "hir", "ide-db", - "itertools", + "itertools 0.12.0", "once_cell", "profile", "serde_json", @@ -750,7 +750,7 @@ dependencies = [ "expect-test", "hir", "ide-db", - "itertools", + "itertools 0.12.0", "nohash-hasher", "parser", "stdx", @@ -838,6 +838,15 @@ dependencies = [ "either", ] +[[package]] +name = "itertools" +version = "0.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "25db6b064527c5d482d0423354fcd07a89a2dfe07b67892e62411946db7f07b0" +dependencies = [ + "either", +] + [[package]] name = "itoa" version = "1.0.6" @@ -942,7 +951,7 @@ dependencies = [ "crossbeam-channel", "ide", "ide-db", - "itertools", + "itertools 0.12.0", "proc-macro-api", "project-model", "tracing", @@ -1389,7 +1398,7 @@ dependencies = [ "cargo_metadata", "cfg", "expect-test", - "itertools", + "itertools 0.12.0", "la-arena 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", "paths", "profile", @@ -1583,7 +1592,7 @@ dependencies = [ "ide", "ide-db", "ide-ssr", - "itertools", + "itertools 0.12.0", "load-cargo", "lsp-server 0.7.4 (registry+https://github.com/rust-lang/crates.io-index)", "lsp-types", @@ -1860,7 +1869,7 @@ dependencies = [ "either", "expect-test", "indexmap 2.0.0", - "itertools", + "itertools 0.12.0", "once_cell", "parser", "proc-macro2", @@ -1894,7 +1903,7 @@ dependencies = [ name = "text-edit" version = "0.0.0" dependencies = [ - "itertools", + "itertools 0.12.0", "text-size", ] diff --git a/Cargo.toml b/Cargo.toml index 789d423ac20..3dda3582be1 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -91,6 +91,7 @@ lsp-server = { version = "0.7.4" } # non-local crates anyhow = "1.0.75" +itertools = "0.12.0" smallvec = { version = "1.10.0", features = [ "const_new", "union", diff --git a/crates/hir-def/Cargo.toml b/crates/hir-def/Cargo.toml index 99b8e9bf0e1..cd0fe624717 100644 --- a/crates/hir-def/Cargo.toml +++ b/crates/hir-def/Cargo.toml @@ -21,7 +21,7 @@ drop_bomb = "0.1.5" either = "1.7.0" fst = { version = "0.4.7", default-features = false } indexmap = "2.0.0" -itertools = "0.10.5" +itertools.workspace = true la-arena.workspace = true once_cell = "1.17.0" rustc-hash = "1.1.0" diff --git a/crates/hir-expand/Cargo.toml b/crates/hir-expand/Cargo.toml index 1f27204c191..97d99a69ab0 100644 --- a/crates/hir-expand/Cargo.toml +++ b/crates/hir-expand/Cargo.toml @@ -17,7 +17,7 @@ tracing = "0.1.35" either = "1.7.0" rustc-hash = "1.1.0" la-arena.workspace = true -itertools = "0.10.5" +itertools.workspace = true hashbrown.workspace = true smallvec.workspace = true triomphe.workspace = true diff --git a/crates/hir-ty/Cargo.toml b/crates/hir-ty/Cargo.toml index c30807ad884..3699df98ec5 100644 --- a/crates/hir-ty/Cargo.toml +++ b/crates/hir-ty/Cargo.toml @@ -13,7 +13,7 @@ doctest = false [dependencies] cov-mark = "2.0.0-pre.1" -itertools = "0.10.5" +itertools.workspace = true arrayvec = "0.7.2" bitflags = "2.1.0" smallvec.workspace = true diff --git a/crates/hir/Cargo.toml b/crates/hir/Cargo.toml index 09ab60dd549..2df9be88f03 100644 --- a/crates/hir/Cargo.toml +++ b/crates/hir/Cargo.toml @@ -15,7 +15,7 @@ doctest = false rustc-hash = "1.1.0" either = "1.7.0" arrayvec = "0.7.2" -itertools = "0.10.5" +itertools.workspace = true smallvec.workspace = true triomphe.workspace = true once_cell = "1.17.1" diff --git a/crates/ide-assists/Cargo.toml b/crates/ide-assists/Cargo.toml index 447e38f91f4..2496169a6b2 100644 --- a/crates/ide-assists/Cargo.toml +++ b/crates/ide-assists/Cargo.toml @@ -14,7 +14,7 @@ doctest = false [dependencies] cov-mark = "2.0.0-pre.1" -itertools = "0.10.5" +itertools.workspace = true either = "1.7.0" smallvec.workspace = true diff --git a/crates/ide-completion/Cargo.toml b/crates/ide-completion/Cargo.toml index 092fb303668..60f90a41b96 100644 --- a/crates/ide-completion/Cargo.toml +++ b/crates/ide-completion/Cargo.toml @@ -13,7 +13,7 @@ doctest = false [dependencies] cov-mark = "2.0.0-pre.1" -itertools = "0.10.5" +itertools.workspace = true once_cell = "1.17.0" smallvec.workspace = true diff --git a/crates/ide-db/Cargo.toml b/crates/ide-db/Cargo.toml index faec7420681..409748fa73e 100644 --- a/crates/ide-db/Cargo.toml +++ b/crates/ide-db/Cargo.toml @@ -19,7 +19,7 @@ fst = { version = "0.4.7", default-features = false } rustc-hash = "1.1.0" once_cell = "1.17.0" either = "1.7.0" -itertools = "0.10.5" +itertools.workspace = true arrayvec = "0.7.2" indexmap = "2.0.0" memchr = "2.5.0" diff --git a/crates/ide-db/src/source_change.rs b/crates/ide-db/src/source_change.rs index 39763479c65..c7188f1f794 100644 --- a/crates/ide-db/src/source_change.rs +++ b/crates/ide-db/src/source_change.rs @@ -140,10 +140,10 @@ impl SnippetEdit { .with_position() .map(|pos| { let (snippet, index) = match pos { - itertools::Position::First(it) | itertools::Position::Middle(it) => it, + (itertools::Position::First, it) | (itertools::Position::Middle, it) => it, // last/only snippet gets index 0 - itertools::Position::Last((snippet, _)) - | itertools::Position::Only((snippet, _)) => (snippet, 0), + (itertools::Position::Last, (snippet, _)) + | (itertools::Position::Only, (snippet, _)) => (snippet, 0), }; let range = match snippet { diff --git a/crates/ide-diagnostics/Cargo.toml b/crates/ide-diagnostics/Cargo.toml index 14aa3940199..1e455dcfd65 100644 --- a/crates/ide-diagnostics/Cargo.toml +++ b/crates/ide-diagnostics/Cargo.toml @@ -14,7 +14,7 @@ doctest = false [dependencies] cov-mark = "2.0.0-pre.1" either = "1.7.0" -itertools = "0.10.5" +itertools.workspace = true serde_json = "1.0.86" once_cell = "1.17.0" diff --git a/crates/ide-ssr/Cargo.toml b/crates/ide-ssr/Cargo.toml index 70ed6dea5bf..56b29f92b82 100644 --- a/crates/ide-ssr/Cargo.toml +++ b/crates/ide-ssr/Cargo.toml @@ -14,7 +14,7 @@ doctest = false [dependencies] cov-mark = "2.0.0-pre.1" -itertools = "0.10.5" +itertools.workspace = true triomphe.workspace = true nohash-hasher.workspace = true diff --git a/crates/ide/Cargo.toml b/crates/ide/Cargo.toml index 2aee203c4ea..90e7847bc86 100644 --- a/crates/ide/Cargo.toml +++ b/crates/ide/Cargo.toml @@ -15,7 +15,7 @@ doctest = false cov-mark = "2.0.0-pre.1" crossbeam-channel = "0.5.5" either = "1.7.0" -itertools = "0.10.5" +itertools.workspace = true tracing = "0.1.35" oorandom = "11.1.3" pulldown-cmark-to-cmark = "10.0.4" diff --git a/crates/load-cargo/Cargo.toml b/crates/load-cargo/Cargo.toml index 26cfe8ead4b..e31b0c2c814 100644 --- a/crates/load-cargo/Cargo.toml +++ b/crates/load-cargo/Cargo.toml @@ -13,7 +13,7 @@ authors.workspace = true [dependencies] anyhow.workspace = true crossbeam-channel = "0.5.5" -itertools = "0.10.5" +itertools.workspace = true tracing = "0.1.35" ide.workspace = true diff --git a/crates/project-model/Cargo.toml b/crates/project-model/Cargo.toml index 99314ec889b..11dba4494f3 100644 --- a/crates/project-model/Cargo.toml +++ b/crates/project-model/Cargo.toml @@ -21,7 +21,7 @@ serde_json.workspace = true serde.workspace = true triomphe.workspace = true la-arena.workspace = true -itertools = "0.10.5" +itertools.workspace = true # local deps base-db.workspace = true diff --git a/crates/rust-analyzer/Cargo.toml b/crates/rust-analyzer/Cargo.toml index 0af48b0c9a9..90f8577996c 100644 --- a/crates/rust-analyzer/Cargo.toml +++ b/crates/rust-analyzer/Cargo.toml @@ -22,7 +22,7 @@ path = "src/bin/main.rs" anyhow.workspace = true crossbeam-channel = "0.5.5" dissimilar = "1.0.4" -itertools = "0.10.5" +itertools.workspace = true scip = "0.3.1" lsp-types = { version = "=0.94.0", features = ["proposed"] } parking_lot = "0.12.1" diff --git a/crates/syntax/Cargo.toml b/crates/syntax/Cargo.toml index dc92366d1c7..671da08737b 100644 --- a/crates/syntax/Cargo.toml +++ b/crates/syntax/Cargo.toml @@ -15,7 +15,7 @@ doctest = false [dependencies] cov-mark = "2.0.0-pre.1" either = "1.7.0" -itertools = "0.10.5" +itertools.workspace = true rowan = "0.15.11" rustc-hash = "1.1.0" once_cell = "1.17.0" diff --git a/crates/text-edit/Cargo.toml b/crates/text-edit/Cargo.toml index 76d0ca5ccb6..4620cc72d0a 100644 --- a/crates/text-edit/Cargo.toml +++ b/crates/text-edit/Cargo.toml @@ -12,5 +12,5 @@ rust-version.workspace = true doctest = false [dependencies] -itertools = "0.10.5" +itertools.workspace = true text-size.workspace = true