pub struct BytecodeViewer<'a> {
pub lines: Vec<String>,
pub view: BinaryIndexedView<'a>,
pub line_map: HashMap<usize, BytecodeInfo>,
}
Fields§
§lines: Vec<String>
§view: BinaryIndexedView<'a>
§line_map: HashMap<usize, BytecodeInfo>
Implementations§
source§impl<'a> BytecodeViewer<'a>
impl<'a> BytecodeViewer<'a>
Trait Implementations§
source§impl<'a> Clone for BytecodeViewer<'a>
impl<'a> Clone for BytecodeViewer<'a>
source§fn clone(&self) -> BytecodeViewer<'a>
fn clone(&self) -> BytecodeViewer<'a>
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<'a> Debug for BytecodeViewer<'a>
impl<'a> Debug for BytecodeViewer<'a>
source§impl LeftScreen for BytecodeViewer<'_>
impl LeftScreen for BytecodeViewer<'_>
§type SourceIndex = BytecodeInfo
type SourceIndex = BytecodeInfo
This is the type used for indexing the source code in the
RightScreen
trait. e.g., for
bytecode and using the source map, this would be a tuple of (FunctionDefinitionIndex, CodeOffset)
.source§fn get_source_index_for_line(
&self,
line: usize,
_column: usize
) -> Option<&Self::SourceIndex>
fn get_source_index_for_line( &self, line: usize, _column: usize ) -> Option<&Self::SourceIndex>
Given a
line
and the column
within that line, this returns a SourceIndex
to be used
by the RightScreen
trait.source§fn backing_string(&self) -> String
fn backing_string(&self) -> String
Return the backing string to be displayed on the left screen.
source§impl<'a> RightScreen<BytecodeViewer<'a>> for ModuleViewer
impl<'a> RightScreen<BytecodeViewer<'a>> for ModuleViewer
source§fn source_for_code_location(
&self,
bytecode_info: &BytecodeInfo
) -> Result<SourceContext>
fn source_for_code_location( &self, bytecode_info: &BytecodeInfo ) -> Result<SourceContext>
Take a
SourceIndex
from the Indexer
and turn it into a context that will be diplayed on
the right screen.