Skip to content

Commit f1e2419

Browse files
committed
programmemory.cpp: avoid unnecessary copy in ProgramMemoryState::get() [skip ci]
1 parent 8e0b759 commit f1e2419

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

lib/programmemory.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -605,7 +605,7 @@ ProgramMemory ProgramMemoryState::get(const Token* tok, const Token* ctx, const
605605
} else {
606606
local.removeModifiedVars(ctx);
607607
}
608-
return local.state;
608+
return std::move(local.state);
609609
}
610610

611611
ProgramMemory getProgramMemory(const Token* tok, const Token* expr, const ValueFlow::Value& value, const Settings& settings)

0 commit comments

Comments
 (0)