pub struct SourceSpan {
pub start_byte: usize,
pub end_byte: usize,
pub start_line: u32,
pub start_column: u32,
}Expand description
A source position span, recorded for reporting only.
start_byte/end_byte are byte offsets into the source; start_line and
start_column are 1-based and counted in characters. None of these fields
may be used to derive a stable identifier.
Fields§
§start_byte: usizeByte offset of the span start.
end_byte: usizeByte offset one past the span end.
start_line: u321-based line of the span start.
start_column: u321-based column (in characters) of the span start.
Trait Implementations§
Source§impl Clone for SourceSpan
impl Clone for SourceSpan
impl Copy for SourceSpan
Source§impl Debug for SourceSpan
impl Debug for SourceSpan
impl Eq for SourceSpan
Source§impl PartialEq for SourceSpan
impl PartialEq for SourceSpan
impl StructuralPartialEq for SourceSpan
Auto Trait Implementations§
impl Freeze for SourceSpan
impl RefUnwindSafe for SourceSpan
impl Send for SourceSpan
impl Sync for SourceSpan
impl Unpin for SourceSpan
impl UnsafeUnpin for SourceSpan
impl UnwindSafe for SourceSpan
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