mirror of
https://github.com/zeek/zeek.git
synced 2025-10-06 08:38:20 +00:00
Fix various compiler/linter warnings in script_opt/CPP code
This commit is contained in:
parent
e200016200
commit
3e85375010
15 changed files with 43 additions and 41 deletions
|
@ -86,9 +86,8 @@ void CPPCompile::GenAttrs(const AttributesPtr& attrs)
|
|||
|
||||
AddInit(attrs);
|
||||
|
||||
for ( auto i = 0; i < avec.size(); ++i )
|
||||
for ( const auto& attr : avec )
|
||||
{
|
||||
const auto& attr = avec[i];
|
||||
const auto& e = attr->GetExpr();
|
||||
|
||||
if ( ! e )
|
||||
|
@ -171,7 +170,7 @@ const char* CPPCompile::AttrName(const AttrPtr& attr)
|
|||
case ATTR_IS_ASSIGNED: return "ATTR_IS_ASSIGNED";
|
||||
case ATTR_IS_USED: return "ATTR_IS_USED";
|
||||
|
||||
case NUM_ATTRS: return "<busted>";
|
||||
default: return "<busted>";
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue