Auto merge of #113120 - Dylan-DPC:rollup-cz4qr3o, r=Dylan-DPC

Rollup of 6 pull requests

Successful merges:

 - #111571 (Implement proposed API for `proc_macro_span`)
 - #112236 (Simplify computation of killed borrows)
 - #112867 (More `ImplSource` nits)
 - #113019 (add note for non-exhaustive matches with guards)
 - #113094 (Fix invalid HTML DIV tag used in HEAD)
 - #113111 (add myself to review for t-types stuff)

r? `@ghost`
`@rustbot` modify labels: rollup
This commit is contained in:
bors 2023-06-28 13:25:41 +00:00
commit 12950e23f9
2 changed files with 15 additions and 16 deletions

4
Cargo.lock generated
View file

@ -1304,9 +1304,9 @@ version = "0.0.0"
[[package]]
name = "proc-macro2"
version = "1.0.56"
version = "1.0.60"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "2b63bdb0cd06f1f4dedf69b254734f9b45af66e4a031e42a7480257d9898b435"
checksum = "dec2b086b7a862cf4de201096214fa870344cf922b2b30c167badb3af3195406"
dependencies = [
"unicode-ident",
]

View file

@ -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 @@ impl server::Span for RustAnalyzer {
// 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 @@ impl server::Span for RustAnalyzer {
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 {