pub struct SrcPos { /* private fields */ }
Expand description
A source position.
Implementations§
Source§impl SrcPos
impl SrcPos
Sourcepub fn new(off: i32, lc: LineColPos) -> Self
pub fn new(off: i32, lc: LineColPos) -> Self
Creates a new source position.
Sourcepub fn line_col_pos(&self) -> LineColPos
pub fn line_col_pos(&self) -> LineColPos
Gets the line and column position of the source position.
Trait Implementations§
Source§impl Ord for SrcPos
impl Ord for SrcPos
Source§impl PartialOrd for SrcPos
impl PartialOrd for SrcPos
impl Copy for SrcPos
impl Eq for SrcPos
impl StructuralPartialEq for SrcPos
Auto Trait Implementations§
impl Freeze for SrcPos
impl RefUnwindSafe for SrcPos
impl Send for SrcPos
impl Sync for SrcPos
impl Unpin for SrcPos
impl UnwindSafe for SrcPos
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