diff options
-rw-r--r-- | crates/cli/Cargo.toml | 1 | ||||
-rw-r--r-- | crates/cli/src/main.rs | 4 | ||||
-rw-r--r-- | crates/libeditor/src/lib.rs | 2 | ||||
-rw-r--r-- | crates/libeditor/tests/test.rs | 3 |
4 files changed, 7 insertions, 3 deletions
diff --git a/crates/cli/Cargo.toml b/crates/cli/Cargo.toml index ac89a48d3..7dbbe3f4e 100644 --- a/crates/cli/Cargo.toml +++ b/crates/cli/Cargo.toml | |||
@@ -7,5 +7,6 @@ publish = false | |||
7 | [dependencies] | 7 | [dependencies] |
8 | clap = "2.32.0" | 8 | clap = "2.32.0" |
9 | failure = "0.1.1" | 9 | failure = "0.1.1" |
10 | libsyntax2 = { path = "../libsyntax2" } | ||
10 | libeditor = { path = "../libeditor" } | 11 | libeditor = { path = "../libeditor" } |
11 | tools = { path = "../tools" } | 12 | tools = { path = "../tools" } |
diff --git a/crates/cli/src/main.rs b/crates/cli/src/main.rs index fc28691fc..bcb0c9b98 100644 --- a/crates/cli/src/main.rs +++ b/crates/cli/src/main.rs | |||
@@ -1,6 +1,7 @@ | |||
1 | extern crate clap; | 1 | extern crate clap; |
2 | #[macro_use] | 2 | #[macro_use] |
3 | extern crate failure; | 3 | extern crate failure; |
4 | extern crate libsyntax2; | ||
4 | extern crate libeditor; | 5 | extern crate libeditor; |
5 | extern crate tools; | 6 | extern crate tools; |
6 | 7 | ||
@@ -10,7 +11,8 @@ use std::{ | |||
10 | }; | 11 | }; |
11 | use clap::{App, Arg, SubCommand}; | 12 | use clap::{App, Arg, SubCommand}; |
12 | use tools::collect_tests; | 13 | use tools::collect_tests; |
13 | use libeditor::{File, syntax_tree, file_structure}; | 14 | use libsyntax2::File; |
15 | use libeditor::{syntax_tree, file_structure}; | ||
14 | 16 | ||
15 | type Result<T> = ::std::result::Result<T, failure::Error>; | 17 | type Result<T> = ::std::result::Result<T, failure::Error>; |
16 | 18 | ||
diff --git a/crates/libeditor/src/lib.rs b/crates/libeditor/src/lib.rs index a6e6deba7..da337cca0 100644 --- a/crates/libeditor/src/lib.rs +++ b/crates/libeditor/src/lib.rs | |||
@@ -10,11 +10,11 @@ mod code_actions; | |||
10 | mod typing; | 10 | mod typing; |
11 | 11 | ||
12 | use libsyntax2::{ | 12 | use libsyntax2::{ |
13 | File, TextUnit, TextRange, | ||
13 | ast::{AstNode, NameOwner}, | 14 | ast::{AstNode, NameOwner}, |
14 | algo::{walk, find_leaf_at_offset}, | 15 | algo::{walk, find_leaf_at_offset}, |
15 | SyntaxKind::{self, *}, | 16 | SyntaxKind::{self, *}, |
16 | }; | 17 | }; |
17 | pub use libsyntax2::{File, TextRange, TextUnit}; | ||
18 | pub use self::{ | 18 | pub use self::{ |
19 | line_index::{LineIndex, LineCol}, | 19 | line_index::{LineIndex, LineCol}, |
20 | extend_selection::extend_selection, | 20 | extend_selection::extend_selection, |
diff --git a/crates/libeditor/tests/test.rs b/crates/libeditor/tests/test.rs index 3114a128e..ab325c520 100644 --- a/crates/libeditor/tests/test.rs +++ b/crates/libeditor/tests/test.rs | |||
@@ -4,8 +4,9 @@ extern crate libsyntax2; | |||
4 | extern crate assert_eq_text; | 4 | extern crate assert_eq_text; |
5 | 5 | ||
6 | use assert_eq_text::{assert_eq_dbg}; | 6 | use assert_eq_text::{assert_eq_dbg}; |
7 | use libsyntax2::{File, TextUnit, TextRange}; | ||
7 | use libeditor::{ | 8 | use libeditor::{ |
8 | File, TextUnit, TextRange, ActionResult, | 9 | ActionResult, |
9 | highlight, runnables, extend_selection, file_structure, | 10 | highlight, runnables, extend_selection, file_structure, |
10 | flip_comma, add_derive, add_impl, matching_brace, | 11 | flip_comma, add_derive, add_impl, matching_brace, |
11 | join_lines, | 12 | join_lines, |