mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-30 22:01:37 +00:00
rename ra_ide_api -> ra_ide
This commit is contained in:
parent
d9a36a736b
commit
757e593b25
81 changed files with 48 additions and 48 deletions
|
@ -1,6 +1,6 @@
|
|||
//! FIXME: write short doc here
|
||||
|
||||
use ra_ide_api::{FileId, RunnableKind};
|
||||
use ra_ide::{FileId, RunnableKind};
|
||||
use ra_project_model::{self, ProjectWorkspace, TargetKind};
|
||||
|
||||
use crate::{world::WorldSnapshot, Result};
|
||||
|
|
|
@ -6,7 +6,7 @@ use lsp_types::{
|
|||
SymbolKind, TextDocumentEdit, TextDocumentIdentifier, TextDocumentItem,
|
||||
TextDocumentPositionParams, Url, VersionedTextDocumentIdentifier, WorkspaceEdit,
|
||||
};
|
||||
use ra_ide_api::{
|
||||
use ra_ide::{
|
||||
translate_offset_with_edit, CompletionItem, CompletionItemKind, FileId, FilePosition,
|
||||
FileRange, FileSystemEdit, Fold, FoldKind, InsertTextFormat, LineCol, LineIndex,
|
||||
NavigationTarget, RangeInfo, Severity, SourceChange, SourceFileEdit,
|
||||
|
@ -173,7 +173,7 @@ impl ConvWith<&LineIndex> for Range {
|
|||
}
|
||||
}
|
||||
|
||||
impl Conv for ra_ide_api::Documentation {
|
||||
impl Conv for ra_ide::Documentation {
|
||||
type Output = lsp_types::Documentation;
|
||||
fn conv(self) -> Documentation {
|
||||
Documentation::MarkupContent(MarkupContent {
|
||||
|
@ -183,7 +183,7 @@ impl Conv for ra_ide_api::Documentation {
|
|||
}
|
||||
}
|
||||
|
||||
impl Conv for ra_ide_api::FunctionSignature {
|
||||
impl Conv for ra_ide::FunctionSignature {
|
||||
type Output = lsp_types::SignatureInformation;
|
||||
fn conv(self) -> Self::Output {
|
||||
use lsp_types::{ParameterInformation, ParameterLabel, SignatureInformation};
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
//! Implementation of the LSP for rust-analyzer.
|
||||
//!
|
||||
//! This crate takes Rust-specific analysis results from ra_ide_api and
|
||||
//! This crate takes Rust-specific analysis results from ra_ide and
|
||||
//! translates into LSP types.
|
||||
//!
|
||||
//! It also is the root of all state. `world` module defines the bulk of the
|
||||
|
|
|
@ -9,7 +9,7 @@ use std::{error::Error, fmt, panic, path::PathBuf, sync::Arc, time::Instant};
|
|||
use crossbeam_channel::{select, unbounded, RecvError, Sender};
|
||||
use lsp_server::{Connection, ErrorCode, Message, Notification, Request, RequestId, Response};
|
||||
use lsp_types::{ClientCapabilities, NumberOrString};
|
||||
use ra_ide_api::{Canceled, FeatureFlags, FileId, LibraryData, SourceRootId};
|
||||
use ra_ide::{Canceled, FeatureFlags, FileId, LibraryData, SourceRootId};
|
||||
use ra_prof::profile;
|
||||
use ra_vfs::{VfsTask, Watch};
|
||||
use relative_path::RelativePathBuf;
|
||||
|
|
|
@ -9,7 +9,7 @@ use lsp_types::{
|
|||
Hover, HoverContents, Location, MarkupContent, MarkupKind, Position, PrepareRenameResponse,
|
||||
Range, RenameParams, SymbolInformation, TextDocumentIdentifier, TextEdit, WorkspaceEdit,
|
||||
};
|
||||
use ra_ide_api::{
|
||||
use ra_ide::{
|
||||
AssistId, FileId, FilePosition, FileRange, Query, Runnable, RunnableKind, SearchScope,
|
||||
};
|
||||
use ra_prof::profile;
|
||||
|
@ -162,7 +162,7 @@ pub fn handle_on_type_formatting(
|
|||
let line_index = world.analysis().file_line_index(position.file_id)?;
|
||||
let line_endings = world.file_line_endings(position.file_id);
|
||||
|
||||
// in `ra_ide_api`, the `on_type` invariant is that
|
||||
// in `ra_ide`, the `on_type` invariant is that
|
||||
// `text.char_at(position) == typed_char`.
|
||||
position.offset = position.offset - TextUnit::of_char('.');
|
||||
let char_typed = params.ch.chars().next().unwrap_or('\0');
|
||||
|
@ -894,7 +894,7 @@ pub fn handle_inlay_hints(
|
|||
label: api_type.label.to_string(),
|
||||
range: api_type.range.conv_with(&line_index),
|
||||
kind: match api_type.kind {
|
||||
ra_ide_api::InlayKind::TypeHint => InlayKind::TypeHint,
|
||||
ra_ide::InlayKind::TypeHint => InlayKind::TypeHint,
|
||||
},
|
||||
})
|
||||
.collect())
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
//! FIXME: write short doc here
|
||||
|
||||
use ra_ide_api::FileId;
|
||||
use ra_ide::FileId;
|
||||
use rustc_hash::FxHashSet;
|
||||
|
||||
#[derive(Default, Debug)]
|
||||
|
|
|
@ -9,7 +9,7 @@ use crossbeam_channel::{unbounded, Receiver};
|
|||
use lsp_server::ErrorCode;
|
||||
use lsp_types::Url;
|
||||
use parking_lot::RwLock;
|
||||
use ra_ide_api::{
|
||||
use ra_ide::{
|
||||
Analysis, AnalysisChange, AnalysisHost, CrateGraph, FeatureFlags, FileId, LibraryData,
|
||||
SourceRootId,
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue