From b6ea56ea091ad1dbd765831d8dfe79e4d3cdf004 Mon Sep 17 00:00:00 2001 From: Igor Aleksanov Date: Sat, 24 Oct 2020 11:07:10 +0300 Subject: Make call_info a part of ide_db --- crates/ide/Cargo.toml | 1 - crates/ide/src/call_hierarchy.rs | 2 +- crates/ide/src/lib.rs | 4 ++-- crates/ide/src/syntax_highlighting/injection.rs | 2 +- 4 files changed, 4 insertions(+), 5 deletions(-) (limited to 'crates/ide') diff --git a/crates/ide/Cargo.toml b/crates/ide/Cargo.toml index 76b52fa04..145c6156c 100644 --- a/crates/ide/Cargo.toml +++ b/crates/ide/Cargo.toml @@ -30,7 +30,6 @@ profile = { path = "../profile", version = "0.0.0" } test_utils = { path = "../test_utils", version = "0.0.0" } assists = { path = "../assists", version = "0.0.0" } ssr = { path = "../ssr", version = "0.0.0" } -call_info = { path = "../call_info", version = "0.0.0" } completion = { path = "../completion", version = "0.0.0" } # ide should depend only on the top-level `hir` package. if you need diff --git a/crates/ide/src/call_hierarchy.rs b/crates/ide/src/call_hierarchy.rs index 9d6433fe0..a259d9849 100644 --- a/crates/ide/src/call_hierarchy.rs +++ b/crates/ide/src/call_hierarchy.rs @@ -2,8 +2,8 @@ use indexmap::IndexMap; -use call_info::FnCallNode; use hir::Semantics; +use ide_db::call_info::FnCallNode; use ide_db::RootDatabase; use syntax::{ast, match_ast, AstNode, TextRange}; diff --git a/crates/ide/src/lib.rs b/crates/ide/src/lib.rs index cecfae4c7..d84b970d4 100644 --- a/crates/ide/src/lib.rs +++ b/crates/ide/src/lib.rs @@ -80,10 +80,10 @@ pub use crate::{ Highlight, HighlightModifier, HighlightModifiers, HighlightTag, HighlightedRange, }, }; -pub use call_info::CallInfo; pub use completion::{ CompletionConfig, CompletionItem, CompletionItemKind, CompletionScore, InsertTextFormat, }; +pub use ide_db::call_info::CallInfo; pub use assists::{ utils::MergeBehaviour, Assist, AssistConfig, AssistId, AssistKind, ResolvedAssist, @@ -396,7 +396,7 @@ impl Analysis { /// Computes parameter information for the given call expression. pub fn call_info(&self, position: FilePosition) -> Cancelable> { - self.with_db(|db| call_info::call_info(db, position)) + self.with_db(|db| ide_db::call_info::call_info(db, position)) } /// Computes call hierarchy candidates for the given file position. diff --git a/crates/ide/src/syntax_highlighting/injection.rs b/crates/ide/src/syntax_highlighting/injection.rs index acd91b26c..59a74bc02 100644 --- a/crates/ide/src/syntax_highlighting/injection.rs +++ b/crates/ide/src/syntax_highlighting/injection.rs @@ -3,8 +3,8 @@ use std::{collections::BTreeMap, convert::TryFrom}; use ast::{HasQuotes, HasStringValue}; -use call_info::ActiveParameter; use hir::Semantics; +use ide_db::call_info::ActiveParameter; use itertools::Itertools; use syntax::{ast, AstToken, SyntaxNode, SyntaxToken, TextRange, TextSize}; -- cgit v1.2.3