File tree 3 files changed +8
-5
lines changed
3 files changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -106,7 +106,7 @@ symbolt generate_java_generic_typet::operator()(
106
106
107
107
const java_specialized_generic_class_typet new_java_class{
108
108
generic_name,
109
- class_definition. get_tag () ,
109
+ class_definition,
110
110
replacement_components,
111
111
existing_generic_type.generic_type_arguments ()};
112
112
Original file line number Diff line number Diff line change @@ -192,7 +192,7 @@ typet string_length_type()
192
192
void java_string_library_preprocesst::add_string_type (
193
193
const irep_idt &class_name, symbol_tablet &symbol_table)
194
194
{
195
- class_typet string_type;
195
+ java_class_typet string_type;
196
196
string_type.set_tag (class_name);
197
197
string_type.components ().resize (3 );
198
198
string_type.components ()[0 ].set_name (" @java.lang.Object" );
@@ -204,6 +204,7 @@ void java_string_library_preprocesst::add_string_type(
204
204
string_type.components ()[2 ].set_name (" data" );
205
205
string_type.components ()[2 ].set_pretty_name (" data" );
206
206
string_type.components ()[2 ].type () = pointer_type (java_char_type ());
207
+ string_type.set_access (ID_public);
207
208
string_type.add_base (symbol_typet (" java::java.lang.Object" ));
208
209
if (class_name!=" java.lang.CharSequence" )
209
210
{
Original file line number Diff line number Diff line change @@ -456,20 +456,22 @@ class java_specialized_generic_class_typet : public java_class_typet
456
456
// / parameters and name.
457
457
// / \param generic_name: The new name for the class
458
458
// / (like Generic<java::Float>)
459
- // / \param tag: The name for the original class (like java::Generic)
459
+ // / \param originating_class: The name for the original class (like
460
+ // / java::Generic)
460
461
// / \param new_components: The specialised components
461
462
// / \return The newly constructed class.
462
463
java_specialized_generic_class_typet (
463
464
const irep_idt &generic_name,
464
- const irep_idt &tag ,
465
+ const java_class_typet &originating_class ,
465
466
const struct_typet::componentst &new_components,
466
467
const generic_type_argumentst &specialised_parameters)
467
468
{
468
469
set (ID_C_specialized_generic_java_class, true );
469
470
set (ID_name, " java::" + id2string (generic_name));
470
471
set (ID_base_name, id2string (generic_name));
471
472
components () = new_components;
472
- set_tag (tag);
473
+ set_tag (originating_class.get_tag ());
474
+ set_access (originating_class.get_access ());
473
475
474
476
generic_type_arguments () = specialised_parameters;
475
477
}
You can’t perform that action at this time.
0 commit comments