Adjust reference/move nitpicks in use-def/reduce code

Use std::move() and avoid superfluous copies by assigning to
const-reference in a few places.
This commit is contained in:
Jon Siwek 2021-02-08 17:50:57 -08:00
parent 8d452f58fc
commit b450b90a3e
3 changed files with 5 additions and 5 deletions

View file

@ -108,7 +108,7 @@ public:
// Tells the reducer to replace the given statement during the
// next reduction pass.
void AddStmtToReplace(const Stmt* s_old, StmtPtr s_new)
{ replaced_stmts[s_old] = s_new; }
{ replaced_stmts[s_old] = std::move(s_new); }
// Tells the reducer that it can reclaim the storage associated
// with the omitted statements.