Struct run_make_support::external_deps::llvm::LlvmReadobj
source · pub struct LlvmReadobj {
cmd: Command,
}
Expand description
A llvm-readobj
invocation builder.
Fields§
§cmd: Command
Implementations§
source§impl LlvmReadobj
impl LlvmReadobj
sourcepub fn env_remove<K>(&mut self, key: K) -> &mut Self
pub fn env_remove<K>(&mut self, key: K) -> &mut Self
Remove an environmental variable.
sourcepub fn arg<S>(&mut self, arg: S) -> &mut Self
pub fn arg<S>(&mut self, arg: S) -> &mut Self
Generic command argument provider. Prefer specific helper methods if possible. Note that for some executables, arguments might be platform specific. For C/C++ compilers, arguments might be platform and compiler specific.
sourcepub fn args<V, S>(&mut self, args: V) -> &mut Self
pub fn args<V, S>(&mut self, args: V) -> &mut Self
Generic command arguments provider. Prefer specific helper methods if possible. Note that for some executables, arguments might be platform specific. For C/C++ compilers, arguments might be platform and compiler specific.
sourcepub fn inspect<I>(&mut self, inspector: I) -> &mut Self
pub fn inspect<I>(&mut self, inspector: I) -> &mut Self
Inspect what the underlying Command
is up to the
current construction.
sourcepub fn run(&mut self) -> CompletedProcess
pub fn run(&mut self) -> CompletedProcess
Run the constructed command and assert that it is successfully run.
sourcepub fn run_fail(&mut self) -> CompletedProcess
pub fn run_fail(&mut self) -> CompletedProcess
Run the constructed command and assert that it does not successfully run.
sourcepub fn run_unchecked(&mut self) -> CompletedProcess
pub fn run_unchecked(&mut self) -> CompletedProcess
Run the command but do not check its exit status.
Only use if you explicitly don’t care about the exit status.
Prefer to use Self::run
and Self::run_fail
whenever possible.
sourcepub fn current_dir<P: AsRef<Path>>(&mut self, path: P) -> &mut Self
pub fn current_dir<P: AsRef<Path>>(&mut self, path: P) -> &mut Self
Set the path where the command will be run.
source§impl LlvmReadobj
impl LlvmReadobj
sourcepub fn new() -> Self
pub fn new() -> Self
Construct a new llvm-readobj
invocation with the GNU
output style.
This assumes that llvm-readobj
is available at $LLVM_BIN_DIR/llvm-readobj
.
sourcepub fn elf_output_style(&mut self, style: &str) -> &mut Self
pub fn elf_output_style(&mut self, style: &str) -> &mut Self
Specify the format of the ELF information.
Valid options are LLVM
(default), GNU
, and JSON
.
sourcepub fn file_header(&mut self) -> &mut Self
pub fn file_header(&mut self) -> &mut Self
Pass --file-header
to display file headers.
sourcepub fn program_headers(&mut self) -> &mut Self
pub fn program_headers(&mut self) -> &mut Self
Pass --program-headers
to display program headers.
sourcepub fn symbols(&mut self) -> &mut Self
pub fn symbols(&mut self) -> &mut Self
Pass --symbols
to display the symbol table, including both local
and global symbols.
sourcepub fn dynamic_table(&mut self) -> &mut Self
pub fn dynamic_table(&mut self) -> &mut Self
Pass --dynamic-table
to display the dynamic symbol table.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for LlvmReadobj
impl !RefUnwindSafe for LlvmReadobj
impl Send for LlvmReadobj
impl Sync for LlvmReadobj
impl Unpin for LlvmReadobj
impl !UnwindSafe for LlvmReadobj
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
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 280 bytes