25 out <<
"Class references:\n";
27 out <<
" " << class_ref <<
'\n';
34 annotation.output(out);
38 out <<
"class " <<
name;
43 for(
const auto &field :
fields)
48 for(
const auto &method :
methods)
62 if(!element_value_pairs.empty())
67 for(
const auto &element_value_pair : element_value_pairs)
73 element_value_pair.output(out);
81 std::ostream &out)
const 86 out <<
'"' << element_name <<
'"' <<
'=';
99 const irep_idt &annotation_type_name)
101 const auto annotation_it = std::find_if(
104 [&annotation_type_name](
const annotationt &annotation) {
105 if(annotation.type.id() != ID_pointer)
108 return type.
id() == ID_struct_tag &&
111 if(annotation_it == annotations.end())
113 return *annotation_it;
121 for(
const auto &annotation : annotations)
124 annotation.output(out);
149 out <<
"synchronized ";
152 out <<
" : " << descriptor;
158 for(
const auto &i : instructions)
160 if(!i.source_location.get_line().empty())
161 out <<
" // " << i.source_location <<
'\n';
163 out <<
" " << i.address <<
": ";
167 for(
const auto &arg : i.args)
188 for(
const auto &v : local_variable_table)
190 out <<
" " << v.index <<
": " << v.name <<
' ' 191 << v.descriptor <<
'\n';
199 for(
const auto &annotation : annotations)
202 annotation.output(out);
215 out <<
" : " << descriptor <<
';';
The type of an expression, extends irept.
std::string type2java(const typet &type, const namespacet &ns)
const irep_idt & get_identifier() const
std::string from_expr(const namespacet &ns, const irep_idt &identifier, const exprt &expr)
std::vector< annotationt > annotationst
static optionalt< annotationt > find_annotation(const annotationst &annotations, const irep_idt &annotation_type_name)
Find an annotation given its name.
const irep_idt & id() const
void output(std::ostream &) const
void output(std::ostream &out) const
void output(std::ostream &out) const
nonstd::optional< T > optionalt
A namespacet is essentially one or two symbol tables bound together, to allow for symbol lookups in t...
const struct_tag_typet & to_struct_tag_type(const typet &type)
Cast a typet to a struct_tag_typet.
dstringt has one field, an unsigned integer no which is an index into a static table of strings.
void output(std::ostream &out) const
void output(std::ostream &) const
void output(std::ostream &out) const
const typet & subtype() const
std::string expr2java(const exprt &expr, const namespacet &ns)