pub struct StringLocation {
pub start: usize,
pub end: usize,
pub has_escapes: bool,
pub unescaped_len: Option<usize>,
}
Expand description
String location with metadata
Fields§
§start: usize
Start position of string (after opening quote)
end: usize
End position of string (before closing quote)
has_escapes: bool
Whether string contains escape sequences
unescaped_len: Option<usize>
Estimated length after unescaping
Implementations§
Trait Implementations§
Source§impl Clone for StringLocation
impl Clone for StringLocation
Source§fn clone(&self) -> StringLocation
fn clone(&self) -> StringLocation
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl Freeze for StringLocation
impl RefUnwindSafe for StringLocation
impl Send for StringLocation
impl Sync for StringLocation
impl Unpin for StringLocation
impl UnwindSafe for StringLocation
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