23 out <<
"Class references:\n";
25 out <<
" " << class_ref <<
'\n';
32 annotation.output(out);
36 out <<
"class " <<
name;
41 for(
const auto &field :
fields)
46 for(
const auto &method :
methods)
60 if(!element_value_pairs.empty())
65 for(
const auto &element_value_pair : element_value_pairs)
71 element_value_pair.output(out);
79 std::ostream &out)
const
84 out <<
'"' << element_name <<
'"' <<
'=';
94 std::optional<java_bytecode_parse_treet::annotationt>
97 const irep_idt &annotation_type_name)
99 const auto annotation_it = std::find_if(
102 [&annotation_type_name](
const annotationt &annotation) {
103 if(annotation.type.id() != ID_pointer)
105 const typet &type = to_pointer_type(annotation.type).base_type();
106 return type.id() == ID_struct_tag &&
107 to_struct_tag_type(type).get_identifier() == annotation_type_name;
109 if(annotation_it == annotations.end())
111 return *annotation_it;
119 for(
const auto &annotation : annotations)
122 annotation.output(out);
147 out <<
"synchronized ";
150 out <<
" : " << descriptor;
156 for(
const auto &i : instructions)
158 if(!i.source_location.get_line().empty())
159 out <<
" // " << i.source_location <<
'\n';
161 out <<
" " << i.address <<
": ";
165 for(
const auto &arg : i.args)
186 for(
const auto &v : local_variable_table)
188 out <<
" " << v.index <<
": " << v.name <<
' '
189 << v.descriptor <<
'\n';
197 for(
const auto &annotation : annotations)
200 annotation.output(out);
213 out <<
" : " << descriptor <<
';';
struct bytecode_infot const bytecode_info[]
dstringt has one field, an unsigned integer no which is an index into a static table of strings.
A namespacet is essentially one or two symbol tables bound together, to allow for symbol lookups in t...
std::string type2java(const typet &type, const namespacet &ns)
std::string expr2java(const exprt &expr, const namespacet &ns)
std::string from_expr(const namespacet &ns, const irep_idt &identifier, const exprt &expr)
void output(std::ostream &) const
void output(std::ostream &) const
void output(std::ostream &out) const
void output(std::ostream &out) const
void output(std::ostream &out) const
std::vector< annotationt > annotationst
static std::optional< annotationt > find_annotation(const annotationst &annotations, const irep_idt &annotation_type_name)
Find an annotation given its name.
void output(std::ostream &out) const