Struct move_bytecode_viewer::interfaces::SourceContext
source · [−]Expand description
There are two interfaces–the LeftScreen and RightScreen–that need to be implemented for
the bytecode viewer and these can be mix-and-matched for different implementations.
The LeftScreen is the text that is displayed in the left-hand screen, and is scrollable. The
scrolling in this window will output BytecodeInfo objects. These objects are then consumed by
the RightScreen source_for_code_location function, which outputs text containing a context
(left, remainder) around the source code location identified by the passed in
BytecodeInfo.
Fields
left: Stringhighlight: Stringremainder: StringTrait Implementations
sourceimpl Clone for SourceContext
impl Clone for SourceContext
sourcefn clone(&self) -> SourceContext
fn clone(&self) -> SourceContext
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read more
Auto Trait Implementations
impl RefUnwindSafe for SourceContext
impl Send for SourceContext
impl Sync for SourceContext
impl Unpin for SourceContext
impl UnwindSafe for SourceContext
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more