pub struct QVM { /* private fields */ }
Expand description
A Quake 3 virtual machine image.
A VM consists of instructions and data, where data is separated into
- word-sized data
- byte-sized data (LIT)
- uninitialized data (BSS)
Implementations§
Source§impl QVM
impl QVM
Sourcepub fn new(
code: Vec<Instruction>,
data: Vec<u32>,
lit: Vec<u8>,
bss_length: u32,
) -> Result<QVM>
pub fn new( code: Vec<Instruction>, data: Vec<u32>, lit: Vec<u8>, bss_length: u32, ) -> Result<QVM>
Sourcepub fn instructions(&self) -> &Vec<Instruction>
pub fn instructions(&self) -> &Vec<Instruction>
Returns the instructions of the code segment.
Sourcepub fn bss_length(&self) -> u32
pub fn bss_length(&self) -> u32
Returns the length of the uninitialized BSS segment.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for QVM
impl RefUnwindSafe for QVM
impl Send for QVM
impl Sync for QVM
impl Unpin for QVM
impl UnwindSafe for QVM
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