pub struct InlineLocation {
pub file: String,
pub line: u32,
pub column: u32,
}Expand description
Where an inline-snapshot call sits in the source: enough for the
test-better-accept binary to find the literal and rewrite it.
Built from std::panic::Location at the call site, so file is whatever
path rustc was invoked with (workspace-root-relative in a normal cargo
build).
Fields§
§file: StringThe source file, as Location::caller().file() reports it.
line: u32The 1-based line of the matches_inline_snapshot call.
column: u32The 1-based column of the matches_inline_snapshot call.
Trait Implementations§
Source§impl Clone for InlineLocation
impl Clone for InlineLocation
Source§fn clone(&self) -> InlineLocation
fn clone(&self) -> InlineLocation
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for InlineLocation
impl Debug for InlineLocation
Source§impl PartialEq for InlineLocation
impl PartialEq for InlineLocation
Source§fn eq(&self, other: &InlineLocation) -> bool
fn eq(&self, other: &InlineLocation) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for InlineLocation
impl StructuralPartialEq for InlineLocation
Auto Trait Implementations§
impl Freeze for InlineLocation
impl RefUnwindSafe for InlineLocation
impl Send for InlineLocation
impl Sync for InlineLocation
impl Unpin for InlineLocation
impl UnsafeUnpin for InlineLocation
impl UnwindSafe for InlineLocation
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