mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 14:48:21 +00:00
fixes for correctly tracking which functions have been fully inlined
This commit is contained in:
parent
91d70e6dd4
commit
3f64858335
3 changed files with 17 additions and 7 deletions
|
@ -218,6 +218,8 @@ ExprPtr Inliner::CheckForInlining(CallExprPtr c)
|
|||
return nullptr; // signals "stop inlining"
|
||||
}
|
||||
|
||||
did_inline.insert(func_vf);
|
||||
|
||||
num_stmts += oi->num_stmts;
|
||||
num_exprs += oi->num_exprs;
|
||||
|
||||
|
@ -265,9 +267,9 @@ ExprPtr Inliner::CheckForInlining(CallExprPtr c)
|
|||
else
|
||||
max_inlined_frame_size = hold_max_inlined_frame_size;
|
||||
|
||||
ListExprPtr args = {NewRef{}, c->Args()};
|
||||
auto t = c->GetType();
|
||||
auto ie = make_intrusive<InlineExpr>(args, std::move(params), body_dup, curr_frame_size, t);
|
||||
auto ie = make_intrusive<InlineExpr>(c->ArgsPtr(), std::move(params), body_dup, curr_frame_size,
|
||||
t);
|
||||
ie->SetOriginal(c);
|
||||
|
||||
return ie;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue