Struct symbolic_debuginfo::FileInfo
source · pub struct FileInfo<'data> { /* private fields */ }
Expand description
File information referred by LineInfo
comprising a directory and name.
The file path is usually relative to a compilation directory. It might contain parent directory
segments (../
).
Implementations§
source§impl<'data> FileInfo<'data>
impl<'data> FileInfo<'data>
sourcepub fn new(dir: Cow<'data, [u8]>, name: Cow<'data, [u8]>) -> Self
pub fn new(dir: Cow<'data, [u8]>, name: Cow<'data, [u8]>) -> Self
Creates a FileInfo
with a given directory and the file name.
sourcepub fn from_path(path: &'data [u8]) -> Self
pub fn from_path(path: &'data [u8]) -> Self
Creates a FileInfo
from a joined path by trying to split it.
sourcepub fn from_filename(name: &'data [u8]) -> Self
pub fn from_filename(name: &'data [u8]) -> Self
Creates a FileInfo
with the file name.
Trait Implementations§
source§impl<'data> PartialEq<FileInfo<'data>> for FileInfo<'data>
impl<'data> PartialEq<FileInfo<'data>> for FileInfo<'data>
impl<'data> Eq for FileInfo<'data>
impl<'data> StructuralEq for FileInfo<'data>
impl<'data> StructuralPartialEq for FileInfo<'data>
Auto Trait Implementations§
impl<'data> RefUnwindSafe for FileInfo<'data>
impl<'data> Send for FileInfo<'data>
impl<'data> Sync for FileInfo<'data>
impl<'data> Unpin for FileInfo<'data>
impl<'data> UnwindSafe for FileInfo<'data>
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
source§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.source§impl<I, T> ExtractContext<I, ()> for T
impl<I, T> ExtractContext<I, ()> for T
source§fn extract_context(self, _original_input: I)
fn extract_context(self, _original_input: I)
Given the context attached to a nom error, and given the original
input to the nom parser, extract more the useful context information. Read more
source§impl<I> RecreateContext<I> for I
impl<I> RecreateContext<I> for I
source§fn recreate_context(_original_input: I, tail: I) -> I
fn recreate_context(_original_input: I, tail: I) -> I
Given the original input, as well as the context reported by nom,
recreate a context in the original string where the error occurred. Read more