pub enum CursorPosition {
Nowhere,
At(Inst),
Before(Block),
After(Block),
}
Expand description
The possible positions of a cursor.
Variants§
Nowhere
Cursor is not pointing anywhere. No instructions can be inserted.
At(Inst)
Cursor is pointing at an existing instruction. New instructions will be inserted before the current instruction.
Before(Block)
Cursor is before the beginning of a block. No instructions can be inserted. Calling
next_inst()
will move to the first instruction in the block.
After(Block)
Cursor is pointing after the end of a block. New instructions will be appended to the block.
Trait Implementations§
Source§impl Clone for CursorPosition
impl Clone for CursorPosition
Source§fn clone(&self) -> CursorPosition
fn clone(&self) -> CursorPosition
Returns a copy 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 moreSource§impl Debug for CursorPosition
impl Debug for CursorPosition
Source§impl PartialEq for CursorPosition
impl PartialEq for CursorPosition
impl Copy for CursorPosition
impl Eq for CursorPosition
impl StructuralPartialEq for CursorPosition
Auto Trait Implementations§
impl Freeze for CursorPosition
impl RefUnwindSafe for CursorPosition
impl Send for CursorPosition
impl Sync for CursorPosition
impl Unpin for CursorPosition
impl UnwindSafe for CursorPosition
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<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.