Go to the documentation of this file.
20 &generic_parameter_specialization_map,
30 &generic_parameter_specialization_map)
const
32 auto parameter = type_try_dynamic_cast<java_generic_parametert>(
pointer_type);
33 if(parameter !=
nullptr)
35 irep_idt parameter_name = parameter->get_name();
39 generic_parameter_specialization_map;
43 spec_map_copy.
pop(parameter_name);
54 return *specialization;
64 const auto *array_element_type =
66 if(array_element_type ==
nullptr)
70 *array_element_type, generic_parameter_specialization_map);
73 replacement_array_type.
subtype().
set(ID_element_type, new_array_type);
74 return replacement_array_type;
80 std::set<struct_tag_typet>
dstringt has one field, an unsigned integer no which is an index into a static table of strings.
const typet & subtype() const
Handle selection of correct pointer type (for example changing abstract classes to concrete versions)...
const typet & java_array_element_type(const struct_tag_typet &array_symbol)
Return a const reference to the element type of a given java array type.
bool is_java_array_tag(const irep_idt &tag)
See above.
virtual std::set< struct_tag_typet > get_parameter_alternative_types(const irep_idt &function_name, const irep_idt ¶meter_name, const namespacet &ns) const
Get alternative types for a method parameter, e.g., based on the casts in the function body.
virtual pointer_typet convert_pointer_type(const pointer_typet &pointer_type, const generic_parameter_specialization_mapt &generic_parameter_specialization_map, const namespacet &ns) const
Select what type should be used for a given pointer type.
A namespacet is essentially one or two symbol tables bound together, to allow for symbol lookups in t...
const irep_idt get_name() const
bool is_java_generic_parameter(const typet &type)
Checks whether the type is a java generic parameter/variable, e.g., T in List<T>.
java_reference_typet java_array_type(const char subtype)
Construct an array pointer type.
pointer_typet pointer_type(const typet &subtype)
nonstd::optional< T > optionalt
const java_generic_parametert & to_java_generic_parameter(const typet &type)
void set(const irep_namet &name, const irep_idt &value)
pointer_typet specialize_generics(const pointer_typet &pointer_type, const generic_parameter_specialization_mapt &generic_parameter_specialization_map) const
Specialize generic parameters in a pointer type based on the current map of parameters -> types.
The pointer type These are both 'bitvector_typet' (they have a width) and 'type_with_subtypet' (they ...
void pop(std::size_t container_index)
Pop the top of the specialization stack for a given container.