Feature gate: #![feature(proc_macro_span_shrink)]
This feature adds span.start() and span.end() which give empty spans right at the start and end of the span. (Just like shrink_to_lo() and shrink_to_hi() inside rustc.)
Public API
// proc_macro
impl Span {
pub fn start(&self) -> Span;
pub fn end(&self) -> Span;
}
Steps / History
Unresolved Questions
Feature gate:
#![feature(proc_macro_span_shrink)]This feature adds
span.start()andspan.end()which give empty spans right at the start and end of the span. (Just likeshrink_to_lo()andshrink_to_hi()inside rustc.)Public API
Steps / History
startandend: Implement proposed API forproc_macro_span#111571proc_macro::Spaninspection APIs #54725Unresolved Questions