mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-17 05:25:37 +03:00
Auto merge of #15302 - lnicola:sync-from-rust, r=lnicola
minor: Sync from rust
This commit is contained in:
@@ -8,10 +8,7 @@
|
||||
//!
|
||||
//! FIXME: No span and source file information is implemented yet
|
||||
|
||||
use proc_macro::{
|
||||
bridge::{self, server},
|
||||
LineColumn,
|
||||
};
|
||||
use proc_macro::bridge::{self, server};
|
||||
|
||||
mod token_stream;
|
||||
pub use token_stream::TokenStream;
|
||||
@@ -304,14 +301,6 @@ fn byte_range(&mut self, _span: Self::Span) -> Range<usize> {
|
||||
// FIXME handle span
|
||||
Range { start: 0, end: 0 }
|
||||
}
|
||||
fn start(&mut self, _span: Self::Span) -> LineColumn {
|
||||
// FIXME handle span
|
||||
LineColumn { line: 0, column: 0 }
|
||||
}
|
||||
fn end(&mut self, _span: Self::Span) -> LineColumn {
|
||||
// FIXME handle span
|
||||
LineColumn { line: 0, column: 0 }
|
||||
}
|
||||
fn join(&mut self, first: Self::Span, _second: Self::Span) -> Option<Self::Span> {
|
||||
// Just return the first span again, because some macros will unwrap the result.
|
||||
Some(first)
|
||||
@@ -330,13 +319,23 @@ fn resolved_at(&mut self, _span: Self::Span, _at: Self::Span) -> Self::Span {
|
||||
tt::TokenId::unspecified()
|
||||
}
|
||||
|
||||
fn after(&mut self, _self_: Self::Span) -> Self::Span {
|
||||
fn end(&mut self, _self_: Self::Span) -> Self::Span {
|
||||
tt::TokenId::unspecified()
|
||||
}
|
||||
|
||||
fn before(&mut self, _self_: Self::Span) -> Self::Span {
|
||||
fn start(&mut self, _self_: Self::Span) -> Self::Span {
|
||||
tt::TokenId::unspecified()
|
||||
}
|
||||
|
||||
fn line(&mut self, _span: Self::Span) -> usize {
|
||||
// FIXME handle line
|
||||
0
|
||||
}
|
||||
|
||||
fn column(&mut self, _span: Self::Span) -> usize {
|
||||
// FIXME handle column
|
||||
0
|
||||
}
|
||||
}
|
||||
|
||||
impl server::Symbol for RustAnalyzer {
|
||||
|
||||
Reference in New Issue
Block a user