pub struct Location {
pub line: usize,
pub col: usize,
}
Expand description
Location information
Used for offsets into source. All indexes are 0 based (i.e. row 0, col 0 is the first character of the first line)
Fields§
§line: usize
§col: usize
Implementations§
Trait Implementations§
Source§impl AddAssign for Location
impl AddAssign for Location
Source§fn add_assign(&mut self, rhs: Self)
fn add_assign(&mut self, rhs: Self)
Performs the
+=
operation. Read moreSource§impl Ord for Location
impl Ord for Location
Source§impl PartialOrd for Location
impl PartialOrd for Location
Source§impl SubAssign for Location
impl SubAssign for Location
Source§fn sub_assign(&mut self, rhs: Self)
fn sub_assign(&mut self, rhs: Self)
Performs the
-=
operation. Read moreimpl Copy for Location
impl Eq for Location
impl StructuralPartialEq for Location
Auto Trait Implementations§
impl Freeze for Location
impl RefUnwindSafe for Location
impl Send for Location
impl Sync for Location
impl Unpin for Location
impl UnwindSafe for Location
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