Move the helpers into ide_db

This commit is contained in:
Kirill Bulatov 2020-11-28 16:30:39 +02:00
parent 7b145bd99c
commit 3f612d37c6
27 changed files with 29 additions and 70 deletions

View file

@ -1,5 +1,5 @@
//! Complete fields in record literals and patterns.
use ide_helpers::FamousDefs;
use ide_db::helpers::FamousDefs;
use syntax::ast::Expr;
use crate::{
@ -46,7 +46,7 @@ pub(crate) fn complete_record(acc: &mut Completions, ctx: &CompletionContext) ->
#[cfg(test)]
mod tests {
use expect_test::{expect, Expect};
use ide_helpers::FamousDefs;
use ide_db::helpers::FamousDefs;
use crate::{test_utils::completion_list, CompletionKind};

View file

@ -2,8 +2,8 @@
use either::Either;
use hir::{Adt, ModuleDef, ScopeDef, Type};
use ide_db::helpers::insert_use::ImportScope;
use ide_db::imports_locator;
use ide_helpers::insert_use::ImportScope;
use syntax::AstNode;
use test_utils::mark;

View file

@ -4,7 +4,7 @@
//! module, and we use to statically check that we only produce snippet
//! completions if we are allowed to.
use ide_helpers::insert_use::MergeBehaviour;
use ide_db::helpers::insert_use::MergeBehaviour;
#[derive(Clone, Debug, PartialEq, Eq)]
pub struct CompletionConfig {

View file

@ -3,7 +3,7 @@
use std::fmt;
use hir::{Documentation, ModPath, Mutability};
use ide_helpers::{
use ide_db::helpers::{
insert_use::{self, ImportScope, MergeBehaviour},
mod_path_to_ast,
};

View file

@ -10,8 +10,8 @@ pub(crate) mod type_alias;
mod builder_ext;
use hir::{Documentation, HasAttrs, HirDisplay, ModPath, Mutability, ScopeDef, Type};
use ide_db::helpers::insert_use::{ImportScope, MergeBehaviour};
use ide_db::RootDatabase;
use ide_helpers::insert_use::{ImportScope, MergeBehaviour};
use syntax::TextRange;
use test_utils::mark;