Skip to content

Commit 51e05a8

Browse files
tautschnigpeterschrammel
authored andcommitted
Java front-end: remove unused parameters
1 parent aa7ebbc commit 51e05a8

7 files changed

+1
-20
lines changed

jbmc/src/java_bytecode/java_bytecode_convert_method.cpp

-6
Original file line numberDiff line numberDiff line change
@@ -619,8 +619,6 @@ void java_bytecode_convert_methodt::convert(
619619
if((!m.is_abstract) && (!m.is_native))
620620
method_symbol.value = convert_instructions(
621621
m,
622-
method_type,
623-
method_symbol.name,
624622
to_java_class_type(class_symbol.type).lambda_method_handles());
625623
}
626624

@@ -989,8 +987,6 @@ static std::size_t get_bytecode_type_width(const typet &ty)
989987

990988
codet java_bytecode_convert_methodt::convert_instructions(
991989
const methodt &method,
992-
const code_typet &method_type,
993-
const irep_idt &method_name,
994990
const java_class_typet::java_lambda_method_handlest &lambda_method_handles)
995991
{
996992
const instructionst &instructions=method.instructions;
@@ -3151,7 +3147,6 @@ bool java_bytecode_convert_methodt::is_method_inherited(
31513147
get_inherited_component(
31523148
classname,
31533149
methodid,
3154-
classname,
31553150
symbol_table,
31563151
class_hierarchy,
31573152
false);
@@ -3171,7 +3166,6 @@ irep_idt java_bytecode_convert_methodt::get_static_field(
31713166
get_inherited_component(
31723167
class_identifier,
31733168
component_name,
3174-
symbol_table.lookup_ref(current_method).type.get(ID_C_class),
31753169
symbol_table,
31763170
class_hierarchy,
31773171
true);

jbmc/src/java_bytecode/java_bytecode_convert_method_class.h

-2
Original file line numberDiff line numberDiff line change
@@ -268,8 +268,6 @@ class java_bytecode_convert_methodt:public messaget
268268

269269
codet convert_instructions(
270270
const methodt &,
271-
const code_typet &,
272-
const irep_idt &,
273271
const java_class_typet::java_lambda_method_handlest &);
274272

275273
const bytecode_infot &get_bytecode_info(const irep_idt &statement);

jbmc/src/java_bytecode/java_bytecode_language.cpp

-1
Original file line numberDiff line numberDiff line change
@@ -549,7 +549,6 @@ static void create_stub_global_symbols(
549549
get_inherited_component(
550550
class_id,
551551
component,
552-
"java::" + id2string(parse_tree.parsed_class.name),
553552
symbol_table,
554553
class_hierarchy,
555554
true);

jbmc/src/java_bytecode/java_object_factory.cpp

-6
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,6 @@ class java_object_factoryt
120120
void gen_nondet_pointer_init(
121121
code_blockt &assignments,
122122
const exprt &expr,
123-
const irep_idt &class_identifier,
124123
allocation_typet alloc_type,
125124
const pointer_typet &pointer_type,
126125
size_t depth,
@@ -670,9 +669,6 @@ bool initialize_nondet_string_fields(
670669
/// The code block we are building with initialization code.
671670
/// \param expr:
672671
/// Pointer-typed lvalue expression to initialize.
673-
/// \param class_identifier:
674-
/// Name of the parent class. Used to initialize the `@class_identifier` among
675-
/// others.
676672
/// \param alloc_type:
677673
/// Allocation type (global, local or dynamic)
678674
/// \param depth:
@@ -688,7 +684,6 @@ bool initialize_nondet_string_fields(
688684
void java_object_factoryt::gen_nondet_pointer_init(
689685
code_blockt &assignments,
690686
const exprt &expr,
691-
const irep_idt &class_identifier,
692687
allocation_typet alloc_type,
693688
const pointer_typet &pointer_type,
694689
size_t depth,
@@ -1149,7 +1144,6 @@ void java_object_factoryt::gen_nondet_init(
11491144
gen_nondet_pointer_init(
11501145
assignments,
11511146
expr,
1152-
class_identifier,
11531147
alloc_type,
11541148
pointer_type,
11551149
depth,

jbmc/src/java_bytecode/java_utils.cpp

-4
Original file line numberDiff line numberDiff line change
@@ -331,9 +331,6 @@ std::string pretty_print_java_type(const std::string &fqn_java_type)
331331
/// trying to resolve a reference to A.b, component_class_id is "A".
332332
/// \param component_name: component basename to search for. If searching for
333333
/// A.b, this is "b".
334-
/// \param user_class_id: class identifier making reference to the sought
335-
/// component. The user class is relevant when determining whether package-
336-
/// scoped components are visible from a particular use site.
337334
/// \param symbol_table: global symbol table.
338335
/// \param class_hierarchy: global class hierarchy.
339336
/// \param include_interfaces: if true, search for the given component in all
@@ -343,7 +340,6 @@ std::string pretty_print_java_type(const std::string &fqn_java_type)
343340
resolve_inherited_componentt::inherited_componentt get_inherited_component(
344341
const irep_idt &component_class_id,
345342
const irep_idt &component_name,
346-
const irep_idt &user_class_id,
347343
const symbol_tablet &symbol_table,
348344
const class_hierarchyt &class_hierarchy,
349345
bool include_interfaces)

jbmc/src/java_bytecode/java_utils.h

-1
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,6 @@ std::string pretty_print_java_type(const std::string &fqn_java_type);
103103
resolve_inherited_componentt::inherited_componentt get_inherited_component(
104104
const irep_idt &component_class_id,
105105
const irep_idt &component_name,
106-
const irep_idt &user_class_id,
107106
const symbol_tablet &symbol_table,
108107
const class_hierarchyt &class_hierarchy,
109108
bool include_interfaces);

jbmc/src/java_bytecode/select_pointer_type.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
/// \param pointer_type: The pointer type replace
2222
/// \param generic_parameter_specialization_map map of types for all generic
2323
/// parameters in the current scope
24+
/// \param ns Namespace for type lookups
2425
/// \return A pointer type where the subtype may have been modified
2526
pointer_typet select_pointer_typet::convert_pointer_type(
2627
const pointer_typet &pointer_type,

0 commit comments

Comments
 (0)