diff options
author | Aleksey Kladov <[email protected]> | 2020-08-12 16:03:06 +0100 |
---|---|---|
committer | Aleksey Kladov <[email protected]> | 2020-08-12 16:03:06 +0100 |
commit | 6dafc13f5f776980cd2560fb79d3d4790811c96d (patch) | |
tree | 392c214055eab6a713814d46435bc0d91cf84e6c | |
parent | 7510048ec0a5d5e7136e3ea258954eb244d15baf (diff) |
Rename ra_text_edit -> text_edit
29 files changed, 42 insertions, 42 deletions
diff --git a/Cargo.lock b/Cargo.lock index daa872546..4a6a65934 100644 --- a/Cargo.lock +++ b/Cargo.lock | |||
@@ -927,10 +927,10 @@ dependencies = [ | |||
927 | "ra_hir", | 927 | "ra_hir", |
928 | "ra_ide_db", | 928 | "ra_ide_db", |
929 | "ra_syntax", | 929 | "ra_syntax", |
930 | "ra_text_edit", | ||
931 | "rustc-hash", | 930 | "rustc-hash", |
932 | "stdx", | 931 | "stdx", |
933 | "test_utils", | 932 | "test_utils", |
933 | "text_edit", | ||
934 | ] | 934 | ] |
935 | 935 | ||
936 | [[package]] | 936 | [[package]] |
@@ -1075,10 +1075,10 @@ dependencies = [ | |||
1075 | "ra_ide_db", | 1075 | "ra_ide_db", |
1076 | "ra_ssr", | 1076 | "ra_ssr", |
1077 | "ra_syntax", | 1077 | "ra_syntax", |
1078 | "ra_text_edit", | ||
1079 | "rustc-hash", | 1078 | "rustc-hash", |
1080 | "stdx", | 1079 | "stdx", |
1081 | "test_utils", | 1080 | "test_utils", |
1081 | "text_edit", | ||
1082 | ] | 1082 | ] |
1083 | 1083 | ||
1084 | [[package]] | 1084 | [[package]] |
@@ -1093,11 +1093,11 @@ dependencies = [ | |||
1093 | "ra_db", | 1093 | "ra_db", |
1094 | "ra_hir", | 1094 | "ra_hir", |
1095 | "ra_syntax", | 1095 | "ra_syntax", |
1096 | "ra_text_edit", | ||
1097 | "rayon", | 1096 | "rayon", |
1098 | "rustc-hash", | 1097 | "rustc-hash", |
1099 | "stdx", | 1098 | "stdx", |
1100 | "test_utils", | 1099 | "test_utils", |
1100 | "text_edit", | ||
1101 | ] | 1101 | ] |
1102 | 1102 | ||
1103 | [[package]] | 1103 | [[package]] |
@@ -1177,9 +1177,9 @@ dependencies = [ | |||
1177 | "ra_hir", | 1177 | "ra_hir", |
1178 | "ra_ide_db", | 1178 | "ra_ide_db", |
1179 | "ra_syntax", | 1179 | "ra_syntax", |
1180 | "ra_text_edit", | ||
1181 | "rustc-hash", | 1180 | "rustc-hash", |
1182 | "test_utils", | 1181 | "test_utils", |
1182 | "text_edit", | ||
1183 | ] | 1183 | ] |
1184 | 1184 | ||
1185 | [[package]] | 1185 | [[package]] |
@@ -1191,7 +1191,6 @@ dependencies = [ | |||
1191 | "itertools", | 1191 | "itertools", |
1192 | "once_cell", | 1192 | "once_cell", |
1193 | "ra_parser", | 1193 | "ra_parser", |
1194 | "ra_text_edit", | ||
1195 | "rayon", | 1194 | "rayon", |
1196 | "rowan", | 1195 | "rowan", |
1197 | "rustc-ap-rustc_lexer", | 1196 | "rustc-ap-rustc_lexer", |
@@ -1200,17 +1199,11 @@ dependencies = [ | |||
1200 | "smol_str", | 1199 | "smol_str", |
1201 | "stdx", | 1200 | "stdx", |
1202 | "test_utils", | 1201 | "test_utils", |
1202 | "text_edit", | ||
1203 | "walkdir", | 1203 | "walkdir", |
1204 | ] | 1204 | ] |
1205 | 1205 | ||
1206 | [[package]] | 1206 | [[package]] |
1207 | name = "ra_text_edit" | ||
1208 | version = "0.0.0" | ||
1209 | dependencies = [ | ||
1210 | "text-size", | ||
1211 | ] | ||
1212 | |||
1213 | [[package]] | ||
1214 | name = "rayon" | 1207 | name = "rayon" |
1215 | version = "1.3.1" | 1208 | version = "1.3.1" |
1216 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1209 | source = "registry+https://github.com/rust-lang/crates.io-index" |
@@ -1312,13 +1305,13 @@ dependencies = [ | |||
1312 | "ra_project_model", | 1305 | "ra_project_model", |
1313 | "ra_ssr", | 1306 | "ra_ssr", |
1314 | "ra_syntax", | 1307 | "ra_syntax", |
1315 | "ra_text_edit", | ||
1316 | "rayon", | 1308 | "rayon", |
1317 | "rustc-hash", | 1309 | "rustc-hash", |
1318 | "serde", | 1310 | "serde", |
1319 | "serde_json", | 1311 | "serde_json", |
1320 | "stdx", | 1312 | "stdx", |
1321 | "test_utils", | 1313 | "test_utils", |
1314 | "text_edit", | ||
1322 | "threadpool", | 1315 | "threadpool", |
1323 | "toolchain", | 1316 | "toolchain", |
1324 | "tt", | 1317 | "tt", |
@@ -1566,6 +1559,13 @@ source = "registry+https://github.com/rust-lang/crates.io-index" | |||
1566 | checksum = "f03e7efdedc3bc78cb2337f1e2785c39e45f5ef762d9e4ebb137fff7380a6d8a" | 1559 | checksum = "f03e7efdedc3bc78cb2337f1e2785c39e45f5ef762d9e4ebb137fff7380a6d8a" |
1567 | 1560 | ||
1568 | [[package]] | 1561 | [[package]] |
1562 | name = "text_edit" | ||
1563 | version = "0.0.0" | ||
1564 | dependencies = [ | ||
1565 | "text-size", | ||
1566 | ] | ||
1567 | |||
1568 | [[package]] | ||
1569 | name = "thin-dst" | 1569 | name = "thin-dst" |
1570 | version = "1.1.0" | 1570 | version = "1.1.0" |
1571 | source = "registry+https://github.com/rust-lang/crates.io-index" | 1571 | source = "registry+https://github.com/rust-lang/crates.io-index" |
diff --git a/crates/ra_assists/Cargo.toml b/crates/ra_assists/Cargo.toml index 6f5ace941..e4a5ee6c1 100644 --- a/crates/ra_assists/Cargo.toml +++ b/crates/ra_assists/Cargo.toml | |||
@@ -16,7 +16,7 @@ either = "1.5.3" | |||
16 | stdx = { path = "../stdx" } | 16 | stdx = { path = "../stdx" } |
17 | 17 | ||
18 | ra_syntax = { path = "../ra_syntax" } | 18 | ra_syntax = { path = "../ra_syntax" } |
19 | ra_text_edit = { path = "../ra_text_edit" } | 19 | text_edit = { path = "../text_edit" } |
20 | ra_fmt = { path = "../ra_fmt" } | 20 | ra_fmt = { path = "../ra_fmt" } |
21 | profile = { path = "../profile" } | 21 | profile = { path = "../profile" } |
22 | ra_db = { path = "../ra_db" } | 22 | ra_db = { path = "../ra_db" } |
diff --git a/crates/ra_assists/src/assist_context.rs b/crates/ra_assists/src/assist_context.rs index afba860d1..fcaa1aedc 100644 --- a/crates/ra_assists/src/assist_context.rs +++ b/crates/ra_assists/src/assist_context.rs | |||
@@ -15,7 +15,7 @@ use ra_syntax::{ | |||
15 | AstNode, SourceFile, SyntaxElement, SyntaxKind, SyntaxNode, SyntaxToken, TextRange, TextSize, | 15 | AstNode, SourceFile, SyntaxElement, SyntaxKind, SyntaxNode, SyntaxToken, TextRange, TextSize, |
16 | TokenAtOffset, | 16 | TokenAtOffset, |
17 | }; | 17 | }; |
18 | use ra_text_edit::{TextEdit, TextEditBuilder}; | 18 | use text_edit::{TextEdit, TextEditBuilder}; |
19 | 19 | ||
20 | use crate::{ | 20 | use crate::{ |
21 | assist_config::{AssistConfig, SnippetCap}, | 21 | assist_config::{AssistConfig, SnippetCap}, |
diff --git a/crates/ra_assists/src/utils/insert_use.rs b/crates/ra_assists/src/utils/insert_use.rs index 32780fceb..13dbe1919 100644 --- a/crates/ra_assists/src/utils/insert_use.rs +++ b/crates/ra_assists/src/utils/insert_use.rs | |||
@@ -2,6 +2,7 @@ | |||
2 | // FIXME: rewrite according to the plan, outlined in | 2 | // FIXME: rewrite according to the plan, outlined in |
3 | // https://github.com/rust-analyzer/rust-analyzer/issues/3301#issuecomment-592931553 | 3 | // https://github.com/rust-analyzer/rust-analyzer/issues/3301#issuecomment-592931553 |
4 | 4 | ||
5 | use either::Either; | ||
5 | use hir::{self, ModPath}; | 6 | use hir::{self, ModPath}; |
6 | use ra_syntax::{ | 7 | use ra_syntax::{ |
7 | ast::{self, NameOwner, VisibilityOwner}, | 8 | ast::{self, NameOwner, VisibilityOwner}, |
@@ -9,10 +10,9 @@ use ra_syntax::{ | |||
9 | SyntaxKind::{PATH, PATH_SEGMENT}, | 10 | SyntaxKind::{PATH, PATH_SEGMENT}, |
10 | SyntaxNode, T, | 11 | SyntaxNode, T, |
11 | }; | 12 | }; |
12 | use ra_text_edit::TextEditBuilder; | 13 | use text_edit::TextEditBuilder; |
13 | 14 | ||
14 | use crate::assist_context::AssistContext; | 15 | use crate::assist_context::AssistContext; |
15 | use either::Either; | ||
16 | 16 | ||
17 | /// Determines the containing syntax node in which to insert a `use` statement affecting `position`. | 17 | /// Determines the containing syntax node in which to insert a `use` statement affecting `position`. |
18 | pub(crate) fn find_insert_use_container( | 18 | pub(crate) fn find_insert_use_container( |
diff --git a/crates/ra_ide/Cargo.toml b/crates/ra_ide/Cargo.toml index bbc9ba4e7..84c25f0b8 100644 --- a/crates/ra_ide/Cargo.toml +++ b/crates/ra_ide/Cargo.toml | |||
@@ -22,7 +22,7 @@ oorandom = "11.1.2" | |||
22 | stdx = { path = "../stdx" } | 22 | stdx = { path = "../stdx" } |
23 | 23 | ||
24 | ra_syntax = { path = "../ra_syntax" } | 24 | ra_syntax = { path = "../ra_syntax" } |
25 | ra_text_edit = { path = "../ra_text_edit" } | 25 | text_edit = { path = "../text_edit" } |
26 | ra_db = { path = "../ra_db" } | 26 | ra_db = { path = "../ra_db" } |
27 | ra_ide_db = { path = "../ra_ide_db" } | 27 | ra_ide_db = { path = "../ra_ide_db" } |
28 | ra_cfg = { path = "../ra_cfg" } | 28 | ra_cfg = { path = "../ra_cfg" } |
diff --git a/crates/ra_ide/src/completion/complete_postfix.rs b/crates/ra_ide/src/completion/complete_postfix.rs index 8735b9010..42087da8d 100644 --- a/crates/ra_ide/src/completion/complete_postfix.rs +++ b/crates/ra_ide/src/completion/complete_postfix.rs | |||
@@ -4,7 +4,7 @@ use ra_syntax::{ | |||
4 | ast::{self, AstNode}, | 4 | ast::{self, AstNode}, |
5 | TextRange, TextSize, | 5 | TextRange, TextSize, |
6 | }; | 6 | }; |
7 | use ra_text_edit::TextEdit; | 7 | use text_edit::TextEdit; |
8 | 8 | ||
9 | use crate::{ | 9 | use crate::{ |
10 | completion::{ | 10 | completion::{ |
diff --git a/crates/ra_ide/src/completion/complete_trait_impl.rs b/crates/ra_ide/src/completion/complete_trait_impl.rs index d9a0ef167..b397baf10 100644 --- a/crates/ra_ide/src/completion/complete_trait_impl.rs +++ b/crates/ra_ide/src/completion/complete_trait_impl.rs | |||
@@ -37,7 +37,7 @@ use ra_syntax::{ | |||
37 | ast::{self, edit, Impl}, | 37 | ast::{self, edit, Impl}, |
38 | AstNode, SyntaxKind, SyntaxNode, TextRange, T, | 38 | AstNode, SyntaxKind, SyntaxNode, TextRange, T, |
39 | }; | 39 | }; |
40 | use ra_text_edit::TextEdit; | 40 | use text_edit::TextEdit; |
41 | 41 | ||
42 | use crate::{ | 42 | use crate::{ |
43 | completion::{ | 43 | completion::{ |
diff --git a/crates/ra_ide/src/completion/completion_context.rs b/crates/ra_ide/src/completion/completion_context.rs index 4aa761148..0cb57fb1b 100644 --- a/crates/ra_ide/src/completion/completion_context.rs +++ b/crates/ra_ide/src/completion/completion_context.rs | |||
@@ -9,7 +9,7 @@ use ra_syntax::{ | |||
9 | SyntaxKind::*, | 9 | SyntaxKind::*, |
10 | SyntaxNode, SyntaxToken, TextRange, TextSize, | 10 | SyntaxNode, SyntaxToken, TextRange, TextSize, |
11 | }; | 11 | }; |
12 | use ra_text_edit::Indel; | 12 | use text_edit::Indel; |
13 | 13 | ||
14 | use super::patterns::{ | 14 | use super::patterns::{ |
15 | has_bind_pat_parent, has_block_expr_parent, has_impl_as_prev_sibling, has_impl_parent, | 15 | has_bind_pat_parent, has_block_expr_parent, has_impl_as_prev_sibling, has_impl_parent, |
diff --git a/crates/ra_ide/src/completion/completion_item.rs b/crates/ra_ide/src/completion/completion_item.rs index 7bdda316c..1c0684f4e 100644 --- a/crates/ra_ide/src/completion/completion_item.rs +++ b/crates/ra_ide/src/completion/completion_item.rs | |||
@@ -4,7 +4,7 @@ use std::fmt; | |||
4 | 4 | ||
5 | use hir::Documentation; | 5 | use hir::Documentation; |
6 | use ra_syntax::TextRange; | 6 | use ra_syntax::TextRange; |
7 | use ra_text_edit::TextEdit; | 7 | use text_edit::TextEdit; |
8 | 8 | ||
9 | use crate::completion::completion_config::SnippetCap; | 9 | use crate::completion::completion_config::SnippetCap; |
10 | 10 | ||
diff --git a/crates/ra_ide/src/diagnostics.rs b/crates/ra_ide/src/diagnostics.rs index e006c7775..54810d5bb 100644 --- a/crates/ra_ide/src/diagnostics.rs +++ b/crates/ra_ide/src/diagnostics.rs | |||
@@ -14,7 +14,7 @@ use ra_syntax::{ | |||
14 | ast::{self, AstNode}, | 14 | ast::{self, AstNode}, |
15 | SyntaxNode, TextRange, T, | 15 | SyntaxNode, TextRange, T, |
16 | }; | 16 | }; |
17 | use ra_text_edit::TextEdit; | 17 | use text_edit::TextEdit; |
18 | 18 | ||
19 | use crate::{Diagnostic, FileId, Fix, SourceFileEdit}; | 19 | use crate::{Diagnostic, FileId, Fix, SourceFileEdit}; |
20 | 20 | ||
diff --git a/crates/ra_ide/src/diagnostics/diagnostics_with_fix.rs b/crates/ra_ide/src/diagnostics/diagnostics_with_fix.rs index 88e593e00..8fb25de6c 100644 --- a/crates/ra_ide/src/diagnostics/diagnostics_with_fix.rs +++ b/crates/ra_ide/src/diagnostics/diagnostics_with_fix.rs | |||
@@ -13,7 +13,7 @@ use ra_ide_db::{ | |||
13 | RootDatabase, | 13 | RootDatabase, |
14 | }; | 14 | }; |
15 | use ra_syntax::{algo, ast, AstNode}; | 15 | use ra_syntax::{algo, ast, AstNode}; |
16 | use ra_text_edit::TextEdit; | 16 | use text_edit::TextEdit; |
17 | 17 | ||
18 | /// A [Diagnostic] that potentially has a fix available. | 18 | /// A [Diagnostic] that potentially has a fix available. |
19 | /// | 19 | /// |
diff --git a/crates/ra_ide/src/join_lines.rs b/crates/ra_ide/src/join_lines.rs index 1c881386f..caf63933a 100644 --- a/crates/ra_ide/src/join_lines.rs +++ b/crates/ra_ide/src/join_lines.rs | |||
@@ -7,7 +7,7 @@ use ra_syntax::{ | |||
7 | SyntaxKind::{self, WHITESPACE}, | 7 | SyntaxKind::{self, WHITESPACE}, |
8 | SyntaxNode, SyntaxToken, TextRange, TextSize, T, | 8 | SyntaxNode, SyntaxToken, TextRange, TextSize, T, |
9 | }; | 9 | }; |
10 | use ra_text_edit::{TextEdit, TextEditBuilder}; | 10 | use text_edit::{TextEdit, TextEditBuilder}; |
11 | 11 | ||
12 | // Feature: Join Lines | 12 | // Feature: Join Lines |
13 | // | 13 | // |
diff --git a/crates/ra_ide/src/lib.rs b/crates/ra_ide/src/lib.rs index bfcf5d750..09cb5faf6 100644 --- a/crates/ra_ide/src/lib.rs +++ b/crates/ra_ide/src/lib.rs | |||
@@ -96,7 +96,7 @@ pub use ra_ide_db::{ | |||
96 | RootDatabase, | 96 | RootDatabase, |
97 | }; | 97 | }; |
98 | pub use ra_ssr::SsrError; | 98 | pub use ra_ssr::SsrError; |
99 | pub use ra_text_edit::{Indel, TextEdit}; | 99 | pub use text_edit::{Indel, TextEdit}; |
100 | 100 | ||
101 | pub type Cancelable<T> = Result<T, Canceled>; | 101 | pub type Cancelable<T> = Result<T, Canceled>; |
102 | 102 | ||
diff --git a/crates/ra_ide/src/references/rename.rs b/crates/ra_ide/src/references/rename.rs index 8c1ac3c56..9c688fb06 100644 --- a/crates/ra_ide/src/references/rename.rs +++ b/crates/ra_ide/src/references/rename.rs | |||
@@ -11,9 +11,9 @@ use ra_syntax::{ | |||
11 | ast::{self, NameOwner}, | 11 | ast::{self, NameOwner}, |
12 | lex_single_valid_syntax_kind, match_ast, AstNode, SyntaxKind, SyntaxNode, SyntaxToken, | 12 | lex_single_valid_syntax_kind, match_ast, AstNode, SyntaxKind, SyntaxNode, SyntaxToken, |
13 | }; | 13 | }; |
14 | use ra_text_edit::TextEdit; | ||
15 | use std::convert::TryInto; | 14 | use std::convert::TryInto; |
16 | use test_utils::mark; | 15 | use test_utils::mark; |
16 | use text_edit::TextEdit; | ||
17 | 17 | ||
18 | use crate::{ | 18 | use crate::{ |
19 | references::find_all_refs, FilePosition, FileSystemEdit, RangeInfo, Reference, ReferenceKind, | 19 | references::find_all_refs, FilePosition, FileSystemEdit, RangeInfo, Reference, ReferenceKind, |
@@ -271,9 +271,9 @@ fn rename_reference( | |||
271 | #[cfg(test)] | 271 | #[cfg(test)] |
272 | mod tests { | 272 | mod tests { |
273 | use expect::{expect, Expect}; | 273 | use expect::{expect, Expect}; |
274 | use ra_text_edit::TextEditBuilder; | ||
275 | use stdx::trim_indent; | 274 | use stdx::trim_indent; |
276 | use test_utils::{assert_eq_text, mark}; | 275 | use test_utils::{assert_eq_text, mark}; |
276 | use text_edit::TextEdit; | ||
277 | 277 | ||
278 | use crate::{mock_analysis::analysis_and_position, FileId}; | 278 | use crate::{mock_analysis::analysis_and_position, FileId}; |
279 | 279 | ||
diff --git a/crates/ra_ide/src/typing.rs b/crates/ra_ide/src/typing.rs index d3ce744b4..952429cde 100644 --- a/crates/ra_ide/src/typing.rs +++ b/crates/ra_ide/src/typing.rs | |||
@@ -26,7 +26,7 @@ use ra_syntax::{ | |||
26 | TextRange, TextSize, | 26 | TextRange, TextSize, |
27 | }; | 27 | }; |
28 | 28 | ||
29 | use ra_text_edit::TextEdit; | 29 | use text_edit::TextEdit; |
30 | 30 | ||
31 | use crate::SourceChange; | 31 | use crate::SourceChange; |
32 | 32 | ||
diff --git a/crates/ra_ide/src/typing/on_enter.rs b/crates/ra_ide/src/typing/on_enter.rs index 143b1ae41..c0c5ce3bc 100644 --- a/crates/ra_ide/src/typing/on_enter.rs +++ b/crates/ra_ide/src/typing/on_enter.rs | |||
@@ -9,8 +9,8 @@ use ra_syntax::{ | |||
9 | SyntaxKind::*, | 9 | SyntaxKind::*, |
10 | SyntaxToken, TextRange, TextSize, TokenAtOffset, | 10 | SyntaxToken, TextRange, TextSize, TokenAtOffset, |
11 | }; | 11 | }; |
12 | use ra_text_edit::TextEdit; | ||
13 | use test_utils::mark; | 12 | use test_utils::mark; |
13 | use text_edit::TextEdit; | ||
14 | 14 | ||
15 | // Feature: On Enter | 15 | // Feature: On Enter |
16 | // | 16 | // |
diff --git a/crates/ra_ide_db/Cargo.toml b/crates/ra_ide_db/Cargo.toml index 92b8ef82a..5446a5961 100644 --- a/crates/ra_ide_db/Cargo.toml +++ b/crates/ra_ide_db/Cargo.toml | |||
@@ -22,7 +22,7 @@ either = "1.5.3" | |||
22 | stdx = { path = "../stdx" } | 22 | stdx = { path = "../stdx" } |
23 | 23 | ||
24 | ra_syntax = { path = "../ra_syntax" } | 24 | ra_syntax = { path = "../ra_syntax" } |
25 | ra_text_edit = { path = "../ra_text_edit" } | 25 | text_edit = { path = "../text_edit" } |
26 | ra_db = { path = "../ra_db" } | 26 | ra_db = { path = "../ra_db" } |
27 | profile = { path = "../profile" } | 27 | profile = { path = "../profile" } |
28 | test_utils = { path = "../test_utils" } | 28 | test_utils = { path = "../test_utils" } |
diff --git a/crates/ra_ide_db/src/source_change.rs b/crates/ra_ide_db/src/source_change.rs index abb83f421..ae21132dd 100644 --- a/crates/ra_ide_db/src/source_change.rs +++ b/crates/ra_ide_db/src/source_change.rs | |||
@@ -4,7 +4,7 @@ | |||
4 | //! It can be viewed as a dual for `AnalysisChange`. | 4 | //! It can be viewed as a dual for `AnalysisChange`. |
5 | 5 | ||
6 | use ra_db::FileId; | 6 | use ra_db::FileId; |
7 | use ra_text_edit::TextEdit; | 7 | use text_edit::TextEdit; |
8 | 8 | ||
9 | #[derive(Default, Debug, Clone)] | 9 | #[derive(Default, Debug, Clone)] |
10 | pub struct SourceChange { | 10 | pub struct SourceChange { |
diff --git a/crates/ra_ssr/Cargo.toml b/crates/ra_ssr/Cargo.toml index 84e4b171e..d0f2ae733 100644 --- a/crates/ra_ssr/Cargo.toml +++ b/crates/ra_ssr/Cargo.toml | |||
@@ -11,7 +11,7 @@ repository = "https://github.com/rust-analyzer/rust-analyzer" | |||
11 | doctest = false | 11 | doctest = false |
12 | 12 | ||
13 | [dependencies] | 13 | [dependencies] |
14 | ra_text_edit = { path = "../ra_text_edit" } | 14 | text_edit = { path = "../text_edit" } |
15 | ra_syntax = { path = "../ra_syntax" } | 15 | ra_syntax = { path = "../ra_syntax" } |
16 | ra_db = { path = "../ra_db" } | 16 | ra_db = { path = "../ra_db" } |
17 | ra_ide_db = { path = "../ra_ide_db" } | 17 | ra_ide_db = { path = "../ra_ide_db" } |
diff --git a/crates/ra_ssr/src/replacing.rs b/crates/ra_ssr/src/replacing.rs index 36ced3842..74f9e7db6 100644 --- a/crates/ra_ssr/src/replacing.rs +++ b/crates/ra_ssr/src/replacing.rs | |||
@@ -4,8 +4,8 @@ use crate::matching::Var; | |||
4 | use crate::{resolving::ResolvedRule, Match, SsrMatches}; | 4 | use crate::{resolving::ResolvedRule, Match, SsrMatches}; |
5 | use ra_syntax::ast::{self, AstToken}; | 5 | use ra_syntax::ast::{self, AstToken}; |
6 | use ra_syntax::{SyntaxElement, SyntaxKind, SyntaxNode, SyntaxToken, TextRange, TextSize}; | 6 | use ra_syntax::{SyntaxElement, SyntaxKind, SyntaxNode, SyntaxToken, TextRange, TextSize}; |
7 | use ra_text_edit::TextEdit; | ||
8 | use rustc_hash::{FxHashMap, FxHashSet}; | 7 | use rustc_hash::{FxHashMap, FxHashSet}; |
8 | use text_edit::TextEdit; | ||
9 | 9 | ||
10 | /// Returns a text edit that will replace each match in `matches` with its corresponding replacement | 10 | /// Returns a text edit that will replace each match in `matches` with its corresponding replacement |
11 | /// template. Placeholders in the template will have been substituted with whatever they matched to | 11 | /// template. Placeholders in the template will have been substituted with whatever they matched to |
diff --git a/crates/ra_syntax/Cargo.toml b/crates/ra_syntax/Cargo.toml index fc4d7aa04..f2789e6a3 100644 --- a/crates/ra_syntax/Cargo.toml +++ b/crates/ra_syntax/Cargo.toml | |||
@@ -20,7 +20,7 @@ once_cell = "1.3.1" | |||
20 | 20 | ||
21 | stdx = { path = "../stdx" } | 21 | stdx = { path = "../stdx" } |
22 | 22 | ||
23 | ra_text_edit = { path = "../ra_text_edit" } | 23 | text_edit = { path = "../text_edit" } |
24 | ra_parser = { path = "../ra_parser" } | 24 | ra_parser = { path = "../ra_parser" } |
25 | 25 | ||
26 | # This crate transitively depends on `smol_str` via `rowan`. | 26 | # This crate transitively depends on `smol_str` via `rowan`. |
diff --git a/crates/ra_syntax/fuzz/Cargo.toml b/crates/ra_syntax/fuzz/Cargo.toml index 613ad2857..4cec3c4cd 100644 --- a/crates/ra_syntax/fuzz/Cargo.toml +++ b/crates/ra_syntax/fuzz/Cargo.toml | |||
@@ -11,7 +11,7 @@ cargo-fuzz = true | |||
11 | 11 | ||
12 | [dependencies] | 12 | [dependencies] |
13 | ra_syntax = { path = ".." } | 13 | ra_syntax = { path = ".." } |
14 | ra_text_edit = { path = "../../ra_text_edit" } | 14 | text_edit = { path = "../../text_edit" } |
15 | libfuzzer-sys = { git = "https://github.com/rust-fuzz/libfuzzer-sys.git" } | 15 | libfuzzer-sys = { git = "https://github.com/rust-fuzz/libfuzzer-sys.git" } |
16 | 16 | ||
17 | # Prevent this from interfering with workspaces | 17 | # Prevent this from interfering with workspaces |
diff --git a/crates/ra_syntax/src/algo.rs b/crates/ra_syntax/src/algo.rs index 26b3c813a..6254b38ba 100644 --- a/crates/ra_syntax/src/algo.rs +++ b/crates/ra_syntax/src/algo.rs | |||
@@ -6,8 +6,8 @@ use std::{ | |||
6 | }; | 6 | }; |
7 | 7 | ||
8 | use itertools::Itertools; | 8 | use itertools::Itertools; |
9 | use ra_text_edit::TextEditBuilder; | ||
10 | use rustc_hash::FxHashMap; | 9 | use rustc_hash::FxHashMap; |
10 | use text_edit::TextEditBuilder; | ||
11 | 11 | ||
12 | use crate::{ | 12 | use crate::{ |
13 | AstNode, Direction, NodeOrToken, SyntaxElement, SyntaxKind, SyntaxNode, SyntaxNodePtr, | 13 | AstNode, Direction, NodeOrToken, SyntaxElement, SyntaxKind, SyntaxNode, SyntaxNodePtr, |
diff --git a/crates/ra_syntax/src/fuzz.rs b/crates/ra_syntax/src/fuzz.rs index 39f9b12ab..fbb97aa27 100644 --- a/crates/ra_syntax/src/fuzz.rs +++ b/crates/ra_syntax/src/fuzz.rs | |||
@@ -5,7 +5,7 @@ use std::{ | |||
5 | str::{self, FromStr}, | 5 | str::{self, FromStr}, |
6 | }; | 6 | }; |
7 | 7 | ||
8 | use ra_text_edit::Indel; | 8 | use text_edit::Indel; |
9 | 9 | ||
10 | use crate::{validation, AstNode, SourceFile, TextRange}; | 10 | use crate::{validation, AstNode, SourceFile, TextRange}; |
11 | 11 | ||
diff --git a/crates/ra_syntax/src/lib.rs b/crates/ra_syntax/src/lib.rs index 8a4d45386..465607f55 100644 --- a/crates/ra_syntax/src/lib.rs +++ b/crates/ra_syntax/src/lib.rs | |||
@@ -39,8 +39,8 @@ pub mod fuzz; | |||
39 | 39 | ||
40 | use std::{marker::PhantomData, sync::Arc}; | 40 | use std::{marker::PhantomData, sync::Arc}; |
41 | 41 | ||
42 | use ra_text_edit::Indel; | ||
43 | use stdx::format_to; | 42 | use stdx::format_to; |
43 | use text_edit::Indel; | ||
44 | 44 | ||
45 | pub use crate::{ | 45 | pub use crate::{ |
46 | algo::InsertPosition, | 46 | algo::InsertPosition, |
diff --git a/crates/ra_syntax/src/parsing/reparsing.rs b/crates/ra_syntax/src/parsing/reparsing.rs index ed5a42ea3..6644ffca4 100644 --- a/crates/ra_syntax/src/parsing/reparsing.rs +++ b/crates/ra_syntax/src/parsing/reparsing.rs | |||
@@ -7,7 +7,7 @@ | |||
7 | //! and try to parse only this block. | 7 | //! and try to parse only this block. |
8 | 8 | ||
9 | use ra_parser::Reparser; | 9 | use ra_parser::Reparser; |
10 | use ra_text_edit::Indel; | 10 | use text_edit::Indel; |
11 | 11 | ||
12 | use crate::{ | 12 | use crate::{ |
13 | algo, | 13 | algo, |
diff --git a/crates/rust-analyzer/Cargo.toml b/crates/rust-analyzer/Cargo.toml index 3f70510fd..ef244da59 100644 --- a/crates/rust-analyzer/Cargo.toml +++ b/crates/rust-analyzer/Cargo.toml | |||
@@ -39,7 +39,7 @@ ra_ide = { path = "../ra_ide" } | |||
39 | profile = { path = "../profile" } | 39 | profile = { path = "../profile" } |
40 | ra_project_model = { path = "../ra_project_model" } | 40 | ra_project_model = { path = "../ra_project_model" } |
41 | ra_syntax = { path = "../ra_syntax" } | 41 | ra_syntax = { path = "../ra_syntax" } |
42 | ra_text_edit = { path = "../ra_text_edit" } | 42 | text_edit = { path = "../text_edit" } |
43 | vfs = { path = "../vfs" } | 43 | vfs = { path = "../vfs" } |
44 | vfs-notify = { path = "../vfs-notify" } | 44 | vfs-notify = { path = "../vfs-notify" } |
45 | ra_cfg = { path = "../ra_cfg" } | 45 | ra_cfg = { path = "../ra_cfg" } |
diff --git a/crates/ra_text_edit/Cargo.toml b/crates/text_edit/Cargo.toml index 427862a5c..a69b1ef2b 100644 --- a/crates/ra_text_edit/Cargo.toml +++ b/crates/text_edit/Cargo.toml | |||
@@ -1,5 +1,5 @@ | |||
1 | [package] | 1 | [package] |
2 | name = "ra_text_edit" | 2 | name = "text_edit" |
3 | version = "0.0.0" | 3 | version = "0.0.0" |
4 | license = "MIT OR Apache-2.0" | 4 | license = "MIT OR Apache-2.0" |
5 | authors = ["rust-analyzer developers"] | 5 | authors = ["rust-analyzer developers"] |
diff --git a/crates/ra_text_edit/src/lib.rs b/crates/text_edit/src/lib.rs index ab8cd7fd1..ab8cd7fd1 100644 --- a/crates/ra_text_edit/src/lib.rs +++ b/crates/text_edit/src/lib.rs | |||