Skip to content

Commit b4e146a

Browse files
Add function_id parameter to get_primitive_value_of_object
This is in preparation to giving the function_id to the function generating fresh java symbols.
1 parent 06f89d9 commit b4e146a

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

jbmc/src/java_bytecode/java_string_library_preprocess.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1145,6 +1145,7 @@ code_blockt java_string_library_preprocesst::make_assign_function_from_call(
11451145
/// one of the following: ID_boolean, ID_char, ID_byte, ID_short, ID_int,
11461146
/// ID_long, ID_float, ID_double, ID_void
11471147
/// \param loc: a location in the source
1148+
/// \param function_id: the name of the function
11481149
/// \param symbol_table: the symbol table
11491150
/// \param code: code block to which we are adding some assignments
11501151
/// \return An expression containing a symbol `tmp_type_name` where `type_name`
@@ -1155,6 +1156,7 @@ java_string_library_preprocesst::get_primitive_value_of_object(
11551156
const exprt &object,
11561157
irep_idt type_name,
11571158
const source_locationt &loc,
1159+
const irep_idt &function_id,
11581160
symbol_table_baset &symbol_table,
11591161
code_blockt &code)
11601162
{
@@ -1379,7 +1381,7 @@ struct_exprt java_string_library_preprocesst::make_argument_for_format(
13791381
else if(name==ID_int || name==ID_float || name==ID_char || name==ID_boolean)
13801382
{
13811383
const auto value = get_primitive_value_of_object(
1382-
arg_i, name, loc, symbol_table, code_not_null);
1384+
arg_i, name, loc, function_id, symbol_table, code_not_null);
13831385
if(value.has_value())
13841386
code_not_null.add(code_assignt(field_expr, *value), loc);
13851387
else

jbmc/src/java_bytecode/java_string_library_preprocess.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -327,6 +327,7 @@ class java_string_library_preprocesst:public messaget
327327
const exprt &object,
328328
irep_idt type_name,
329329
const source_locationt &loc,
330+
const irep_idt &function_id,
330331
symbol_table_baset &symbol_table,
331332
code_blockt &code);
332333

0 commit comments

Comments
 (0)