Skip to content

Commit

Permalink
Merge branch 'topic/bbannier/coverity'
Browse files Browse the repository at this point in the history
  • Loading branch information
bbannier committed Jan 13, 2025
2 parents cf21f50 + d4bd71a commit 651c6b1
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 3 deletions.
6 changes: 6 additions & 0 deletions CHANGES
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
1.13.0-dev.68 | 2025-01-13 22:54:50 +0100

* GH-1958: Prevent copies in various places. (Benjamin Bannier, Corelight)

This adds a change incorrectly dropped from #1958.

1.13.0-dev.66 | 2025-01-13 22:09:19 +0100

* Prevent copies in various places. (Benjamin Bannier, Corelight)
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.13.0-dev.66
1.13.0-dev.68
6 changes: 4 additions & 2 deletions hilti/toolchain/src/compiler/codegen/statements.cc
Original file line number Diff line number Diff line change
Expand Up @@ -348,8 +348,10 @@ struct Visitor : hilti::visitor::PreOrder {

if ( init ) {
if ( n->condition() )
outer_wrapper.addLocal(
{cxx::ID(init->id()), cg->compile(init->type(), codegen::TypeUsage::Storage), {}, cxx_init});
outer_wrapper.addLocal({cxx::ID(init->id()),
cg->compile(init->type(), codegen::TypeUsage::Storage),
{},
std::move(cxx_init)});
else
outer_wrapper.addLocal(
{cxx::ID(init->id()), cg->compile(init->type(), codegen::TypeUsage::Storage)});
Expand Down

0 comments on commit 651c6b1

Please sign in to comment.