Skip to content

Commit 2883bb3

Browse files
Avoid unnecessary copy in convert_method.cpp
Without the & we’re copying the items we’re iterating over, which is unnecessary in this case.
1 parent adc0eba commit 2883bb3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

jbmc/unit/java_bytecode/java_bytecode_convert_method/convert_method.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -938,7 +938,7 @@ TEST_CASE(
938938
other_param.type() = java_lang_object_type();
939939
java_method_typet::parameterst parameters{
940940
this_param, ref_to_inner, other_param};
941-
for(const auto param : parameters)
941+
for(const auto &param : parameters)
942942
{
943943
REQUIRE(param.get_identifier().empty());
944944
REQUIRE(param.get_base_name().empty());

0 commit comments

Comments
 (0)