pub struct Spanned<T> {
pub node: T,
pub span: Span,
}Expand description
A value annotated with its source span — carries spans alongside the AST
without putting one inside Term itself.
Consumers: the parser’s spanned body conjuncts (Spanned<Term>, codegen
path) and the compiler’s lowered goal IR (type LGoal = Spanned<LGoalKind>,
SPANS.md Layer 3), where every goal carries its source span so raising
call sites get site_id provenance with no per-variant plumbing. The
undefined-call lint still uses the parser’s flat CallSite occurrences.
Fields§
§node: T§span: SpanImplementations§
Trait Implementations§
Source§impl<T: PartialEq> PartialEq for Spanned<T>
impl<T: PartialEq> PartialEq for Spanned<T>
impl<T: PartialEq> StructuralPartialEq for Spanned<T>
Auto Trait Implementations§
impl<T> Freeze for Spanned<T>where
T: Freeze,
impl<T> RefUnwindSafe for Spanned<T>where
T: RefUnwindSafe,
impl<T> Send for Spanned<T>where
T: Send,
impl<T> Sync for Spanned<T>where
T: Sync,
impl<T> Unpin for Spanned<T>where
T: Unpin,
impl<T> UnsafeUnpin for Spanned<T>where
T: UnsafeUnpin,
impl<T> UnwindSafe for Spanned<T>where
T: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more