low-level tidying

This commit is contained in:
Vern Paxson 2022-05-04 16:52:36 -07:00 committed by Tim Wojtulewicz
parent 415bbe17d6
commit 772169f8e0
3 changed files with 3 additions and 4 deletions

View file

@ -15,7 +15,6 @@
#include "zeek/plugin/Manager.h" #include "zeek/plugin/Manager.h"
zeek::EventMgr zeek::event_mgr; zeek::EventMgr zeek::event_mgr;
zeek::EventMgr& mgr = zeek::event_mgr;
namespace zeek namespace zeek
{ {

View file

@ -22,7 +22,7 @@ public:
const char* Name() const { return name.data(); } const char* Name() const { return name.data(); }
const FuncPtr& GetFunc() { return local; } const FuncPtr& GetFunc() const { return local; }
const FuncTypePtr& GetType(bool check_export = true); const FuncTypePtr& GetType(bool check_export = true);

View file

@ -124,11 +124,11 @@ bool UseDefs::RemoveUnused(int iter)
// Because we're dealing with reduced statements, the // Because we're dealing with reduced statements, the
// assignment expression should be to a simple variable. // assignment expression should be to a simple variable.
if ( r->Tag() != EXPR_REF ) if ( r->Tag() != EXPR_REF )
reporter->InternalError("lhs ref inconsistency in UseDefs::FindUnused"); reporter->InternalError("lhs ref inconsistency in UseDefs::RemoveUnused");
auto n = r->AsRefExprPtr()->GetOp1(); auto n = r->AsRefExprPtr()->GetOp1();
if ( n->Tag() != EXPR_NAME ) if ( n->Tag() != EXPR_NAME )
reporter->InternalError("lhs name inconsistency in UseDefs::FindUnused"); reporter->InternalError("lhs name inconsistency in UseDefs::RemoveUnused");
auto id = n->AsNameExpr()->Id(); auto id = n->AsNameExpr()->Id();