mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 06:38:20 +00:00
Use const auto references to avoid some copies
This commit is contained in:
parent
739efc79be
commit
f7495831a2
5 changed files with 8 additions and 8 deletions
|
@ -320,7 +320,7 @@ void CPPCompile::GenWhenStmt(const WhenInfo* wi, const std::string& when_lambda,
|
|||
vector<string> local_aggrs) {
|
||||
auto is_return = wi->IsReturn() ? "true" : "false";
|
||||
auto timeout = wi->TimeoutExpr();
|
||||
auto timeout_val = timeout ? GenExpr(timeout, GEN_NATIVE) : "-1.0";
|
||||
const auto& timeout_val = timeout ? GenExpr(timeout, GEN_NATIVE) : "-1.0";
|
||||
|
||||
Emit("{ // begin a new scope for internal variables");
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue