mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 14:48:21 +00:00
switch simple loops that don't need indices to being iterator-based
This commit is contained in:
parent
ffd1905f90
commit
d609a11312
8 changed files with 34 additions and 52 deletions
|
@ -79,10 +79,8 @@ bool UseDefs::RemoveUnused(int iter)
|
|||
|
||||
bool did_omission = false;
|
||||
|
||||
for ( unsigned int i = 0; i < stmts.size(); ++i )
|
||||
for ( const auto& s : stmts )
|
||||
{
|
||||
const auto& s = stmts[i];
|
||||
|
||||
if ( s->Tag() == STMT_INIT )
|
||||
{
|
||||
auto init = s->AsInitStmt();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue