pub struct FileEntry<R, Offset = <R as Reader>::Offset>where
R: Reader<Offset = Offset>,
Offset: ReaderOffset,{ /* private fields */ }
Expand description
An entry in the LineProgramHeader
’s file_names
set.
Implementations§
source§impl<R, Offset> FileEntry<R, Offset>where
R: Reader<Offset = Offset>,
Offset: ReaderOffset,
impl<R, Offset> FileEntry<R, Offset>where
R: Reader<Offset = Offset>,
Offset: ReaderOffset,
sourcepub fn path_name(&self) -> AttributeValue<R, Offset>
pub fn path_name(&self) -> AttributeValue<R, Offset>
A slice containing the full or relative path name of a source file. If the entry contains a file name or a relative path name, the file is located relative to either the compilation directory (as specified by the DW_AT_comp_dir attribute given in the compilation unit) or one of the directories in the include_directories section.
sourcepub fn directory_index(&self) -> u64
pub fn directory_index(&self) -> u64
An unsigned LEB128 number representing the directory index of the directory in which the file was found.
…
The directory index represents an entry in the include_directories section of the line number program header. The index is 0 if the file was found in the current directory of the compilation, 1 if it was found in the first directory in the include_directories section, and so on. The directory index is ignored for file names that represent full path names.
sourcepub fn directory(
&self,
header: &LineProgramHeader<R>,
) -> Option<AttributeValue<R, Offset>>
pub fn directory( &self, header: &LineProgramHeader<R>, ) -> Option<AttributeValue<R, Offset>>
Get this file’s directory.
A directory index of 0 corresponds to the compilation unit directory.