ROSE  0.9.9.168
Public Member Functions | Public Attributes | Friends | List of all members
Rose::BinaryAnalysis::Disassembler::Exception Class Reference

Description

Exception thrown by the disassemblers.

Definition at line 44 of file Disassembler.h.

#include <Disassembler.h>

Inheritance diagram for Rose::BinaryAnalysis::Disassembler::Exception:
Inheritance graph
[legend]
Collaboration diagram for Rose::BinaryAnalysis::Disassembler::Exception:
Collaboration graph
[legend]

Public Member Functions

 Exception (const std::string &reason)
 A bare exception not bound to any particular instruction. More...
 
 Exception (const std::string &reason, rose_addr_t ip)
 An exception bound to a virtual address but no raw data or instruction. More...
 
 Exception (const std::string &reason, rose_addr_t ip, const SgUnsignedCharList &raw_data, size_t bit)
 An exception bound to a particular instruction being disassembled. More...
 
 Exception (const std::string &reason, SgAsmInstruction *insn)
 An exception bound to a particular instruction being assembled. More...
 
void print (std::ostream &) const
 

Public Attributes

rose_addr_t ip
 Virtual address where failure occurred; zero if no associated instruction.
 
SgUnsignedCharList bytes
 Bytes (partial) of failed disassembly, including byte at failure. More...
 
size_t bit
 Bit offset in instruction byte sequence where disassembly failed (bit/8 is the index into the "bytes" list, while bit%8 is the bit within that byte. More...
 
SgAsmInstructioninsn
 Instruction associated with an assembly error. More...
 

Friends

std::ostream & operator<< (std::ostream &o, const Exception &e)
 

Constructor & Destructor Documentation

Rose::BinaryAnalysis::Disassembler::Exception::Exception ( const std::string &  reason)
inline

A bare exception not bound to any particular instruction.

Definition at line 47 of file Disassembler.h.

Rose::BinaryAnalysis::Disassembler::Exception::Exception ( const std::string &  reason,
rose_addr_t  ip 
)
inline

An exception bound to a virtual address but no raw data or instruction.

Definition at line 52 of file Disassembler.h.

Rose::BinaryAnalysis::Disassembler::Exception::Exception ( const std::string &  reason,
rose_addr_t  ip,
const SgUnsignedCharList &  raw_data,
size_t  bit 
)
inline

An exception bound to a particular instruction being disassembled.

Definition at line 57 of file Disassembler.h.

Rose::BinaryAnalysis::Disassembler::Exception::Exception ( const std::string &  reason,
SgAsmInstruction insn 
)
inline

An exception bound to a particular instruction being assembled.

Definition at line 62 of file Disassembler.h.

Member Data Documentation

SgUnsignedCharList Rose::BinaryAnalysis::Disassembler::Exception::bytes

Bytes (partial) of failed disassembly, including byte at failure.

Empty if the exception is not associated with a particular byte sequence, such as if an attempt was made to disassemble at an invalid address.

Definition at line 72 of file Disassembler.h.

size_t Rose::BinaryAnalysis::Disassembler::Exception::bit

Bit offset in instruction byte sequence where disassembly failed (bit/8 is the index into the "bytes" list, while bit%8 is the bit within that byte.

Definition at line 75 of file Disassembler.h.

SgAsmInstruction* Rose::BinaryAnalysis::Disassembler::Exception::insn

Instruction associated with an assembly error.

Definition at line 77 of file Disassembler.h.


The documentation for this class was generated from the following file: