diff options
author | bors[bot] <bors[bot]@users.noreply.github.com> | 2019-02-03 18:11:06 +0000 |
---|---|---|
committer | bors[bot] <bors[bot]@users.noreply.github.com> | 2019-02-03 18:11:06 +0000 |
commit | 395965351d467c716f259935557117fe42a8c9f4 (patch) | |
tree | ecda31335d1a9d05b4112dc56345e0f9645eef17 /crates/ra_ide_api/src/imp.rs | |
parent | 55408081b05f79947f7ce4692b31be584aef4657 (diff) | |
parent | bfaefed3f61a29624ea3a0c94fcc498d34d0c31f (diff) |
Merge #733
733: fill match arms r=matklad a=gfreezy
fixed #626
Co-authored-by: gfreezy <[email protected]>
Diffstat (limited to 'crates/ra_ide_api/src/imp.rs')
-rw-r--r-- | crates/ra_ide_api/src/imp.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/crates/ra_ide_api/src/imp.rs b/crates/ra_ide_api/src/imp.rs index 31e0f5d6d..5f672367c 100644 --- a/crates/ra_ide_api/src/imp.rs +++ b/crates/ra_ide_api/src/imp.rs | |||
@@ -10,7 +10,7 @@ use ra_db::{ | |||
10 | SourceDatabase, SourceRoot, SourceRootId, | 10 | SourceDatabase, SourceRoot, SourceRootId, |
11 | salsa::{Database, SweepStrategy}, | 11 | salsa::{Database, SweepStrategy}, |
12 | }; | 12 | }; |
13 | use ra_ide_api_light::{self, assists, LocalEdit, Severity}; | 13 | use ra_ide_api_light::{self, LocalEdit, Severity}; |
14 | use ra_syntax::{ | 14 | use ra_syntax::{ |
15 | algo::find_node_at_offset, ast::{self, NameOwner}, AstNode, | 15 | algo::find_node_at_offset, ast::{self, NameOwner}, AstNode, |
16 | SourceFile, | 16 | SourceFile, |
@@ -238,8 +238,9 @@ impl db::RootDatabase { | |||
238 | 238 | ||
239 | pub(crate) fn assists(&self, frange: FileRange) -> Vec<SourceChange> { | 239 | pub(crate) fn assists(&self, frange: FileRange) -> Vec<SourceChange> { |
240 | let file = self.parse(frange.file_id); | 240 | let file = self.parse(frange.file_id); |
241 | assists::assists(&file, frange.range) | 241 | ra_ide_api_light::assists::assists(&file, frange.range) |
242 | .into_iter() | 242 | .into_iter() |
243 | .chain(crate::assits::assists(self, frange.file_id, &file, frange.range).into_iter()) | ||
243 | .map(|local_edit| SourceChange::from_local_edit(frange.file_id, local_edit)) | 244 | .map(|local_edit| SourceChange::from_local_edit(frange.file_id, local_edit)) |
244 | .collect() | 245 | .collect() |
245 | } | 246 | } |