mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 06:38:20 +00:00
EventHandler: Deprecate SetUsed() and Used() as well.
Seems the latter isn't used outside of the functions that were deprecated in the previous commit and with UsageAnalyzer not making use of this information unclear why we should keep it around. Relates to #3187.
This commit is contained in:
parent
398122206e
commit
ff34a4aa7f
5 changed files with 35 additions and 2 deletions
|
@ -133,7 +133,10 @@ void activate_bodies__CPP(const char* fn, const char* module, bool exported, Typ
|
|||
|
||||
for ( const auto& e : events ) {
|
||||
auto eh = event_registry->Register(e);
|
||||
#pragma GCC diagnostic push
|
||||
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
|
||||
eh->SetUsed();
|
||||
#pragma GCC diagnostic pop
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -190,7 +193,10 @@ FuncValPtr lookup_func__CPP(string name, int num_bodies, vector<p_hash_type> has
|
|||
// the semantics for Register explicitly allow it.
|
||||
for ( auto& e : f.events ) {
|
||||
auto eh = event_registry->Register(e);
|
||||
#pragma GCC diagnostic push
|
||||
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
|
||||
eh->SetUsed();
|
||||
#pragma GCC diagnostic pop
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue