mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-14 14:25:12 +00:00
internal: Split out a span crate
This commit is contained in:
parent
cfc959d73a
commit
66e29be1bd
50 changed files with 477 additions and 403 deletions
|
@ -11,9 +11,9 @@ pub mod msg;
|
|||
mod process;
|
||||
mod version;
|
||||
|
||||
use base_db::span::SpanData;
|
||||
use indexmap::IndexSet;
|
||||
use paths::AbsPathBuf;
|
||||
use span::Span;
|
||||
use std::{fmt, io, sync::Mutex};
|
||||
use triomphe::Arc;
|
||||
|
||||
|
@ -136,13 +136,13 @@ impl ProcMacro {
|
|||
|
||||
pub fn expand(
|
||||
&self,
|
||||
subtree: &tt::Subtree<SpanData>,
|
||||
attr: Option<&tt::Subtree<SpanData>>,
|
||||
subtree: &tt::Subtree<Span>,
|
||||
attr: Option<&tt::Subtree<Span>>,
|
||||
env: Vec<(String, String)>,
|
||||
def_site: SpanData,
|
||||
call_site: SpanData,
|
||||
mixed_site: SpanData,
|
||||
) -> Result<Result<tt::Subtree<SpanData>, PanicMessage>, ServerError> {
|
||||
def_site: Span,
|
||||
call_site: Span,
|
||||
mixed_site: Span,
|
||||
) -> Result<Result<tt::Subtree<Span>, PanicMessage>, ServerError> {
|
||||
let version = self.process.lock().unwrap_or_else(|e| e.into_inner()).version();
|
||||
let current_dir = env
|
||||
.iter()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue