| 76 | /// Code of a given method |
| 77 | #[derive(Debug, Default, PartialEq)] |
| 78 | pub struct ClassFileMethodCode { |
| 79 | /// Maximum depth of the stack at any time |
| 80 | pub max_stack: u16, |
| 81 | /// Number of local variables used by the method |
| 82 | pub max_locals: u16, |
| 83 | /// Raw bytecode |
| 84 | pub code: Vec<u8>, |
| 85 | pub exception_table: ExceptionTable, |
| 86 | pub line_number_table: Option<LineNumberTable>, |
| 87 | |
| 88 | /// Generic unmapped attributes of the code |
| 89 | // TODO: replace with some proper struct |
| 90 | pub attributes: Vec<Attribute>, |
| 91 | } |
| 92 | |
| 93 | impl fmt::Display for ClassFileMethodCode { |
| 94 | fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result { |
nothing calls this directly
no outgoing calls
no test coverage detected