mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 22:58:20 +00:00
CPP code-gen: Use std::move for constructor arguments
This commit is contained in:
parent
73adf2bf01
commit
c9f6b3463f
1 changed files with 1 additions and 1 deletions
|
@ -133,7 +133,7 @@ void CPPCompile::DeclareSubclass(const FuncTypePtr& ft, const ProfileFunc* pf, c
|
||||||
auto tn = FullTypeName(id->GetType());
|
auto tn = FullTypeName(id->GetType());
|
||||||
addl_args = addl_args + ", " + tn + " _" + name;
|
addl_args = addl_args + ", " + tn + " _" + name;
|
||||||
|
|
||||||
inits = inits + ", " + name + "(_" + name + ")";
|
inits = inits + ", " + name + "(std::move(_" + name + "))";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue