Merge #8143
8143: Reexport PrefixKind to remove deps of hir in rust-analyzer crate r=edwin0cheng a=edwin0cheng bors r+ Co-authored-by: Edwin Cheng <edwin0cheng@gmail.com>
This commit is contained in:
commit
27befe6c7f
@ -14,10 +14,12 @@ use syntax::{
|
|||||||
AstToken, InsertPosition, NodeOrToken, SyntaxElement, SyntaxNode, SyntaxToken,
|
AstToken, InsertPosition, NodeOrToken, SyntaxElement, SyntaxNode, SyntaxToken,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
pub use hir::PrefixKind;
|
||||||
|
|
||||||
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
|
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
|
||||||
pub struct InsertUseConfig {
|
pub struct InsertUseConfig {
|
||||||
pub merge: Option<MergeBehavior>,
|
pub merge: Option<MergeBehavior>,
|
||||||
pub prefix_kind: hir::PrefixKind,
|
pub prefix_kind: PrefixKind,
|
||||||
pub group: bool,
|
pub group: bool,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -10,10 +10,9 @@
|
|||||||
use std::{ffi::OsString, iter, path::PathBuf};
|
use std::{ffi::OsString, iter, path::PathBuf};
|
||||||
|
|
||||||
use flycheck::FlycheckConfig;
|
use flycheck::FlycheckConfig;
|
||||||
use hir::PrefixKind;
|
|
||||||
use ide::{AssistConfig, CompletionConfig, DiagnosticsConfig, HoverConfig, InlayHintsConfig};
|
use ide::{AssistConfig, CompletionConfig, DiagnosticsConfig, HoverConfig, InlayHintsConfig};
|
||||||
use ide_db::helpers::{
|
use ide_db::helpers::{
|
||||||
insert_use::{InsertUseConfig, MergeBehavior},
|
insert_use::{InsertUseConfig, MergeBehavior, PrefixKind},
|
||||||
SnippetCap,
|
SnippetCap,
|
||||||
};
|
};
|
||||||
use lsp_types::{ClientCapabilities, MarkupKind};
|
use lsp_types::{ClientCapabilities, MarkupKind};
|
||||||
|
@ -1073,9 +1073,11 @@ pub(crate) fn rename_error(err: RenameError) -> crate::LspError {
|
|||||||
mod tests {
|
mod tests {
|
||||||
use std::sync::Arc;
|
use std::sync::Arc;
|
||||||
|
|
||||||
use hir::PrefixKind;
|
|
||||||
use ide::Analysis;
|
use ide::Analysis;
|
||||||
use ide_db::helpers::{insert_use::InsertUseConfig, SnippetCap};
|
use ide_db::helpers::{
|
||||||
|
insert_use::{InsertUseConfig, PrefixKind},
|
||||||
|
SnippetCap,
|
||||||
|
};
|
||||||
|
|
||||||
use super::*;
|
use super::*;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user