mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 14:48:21 +00:00
Include StmtBase/StmtEnums in Func.h instead of Stmt.h
This requires changes in lots of other files that were depending on Func.h to provide that include for them.
This commit is contained in:
parent
ad50443590
commit
ca3002d745
14 changed files with 31 additions and 3 deletions
|
@ -8,7 +8,9 @@
|
|||
#include <map>
|
||||
#include <vector>
|
||||
|
||||
#include "zeek/Dict.h"
|
||||
#include "zeek/Func.h"
|
||||
#include "zeek/Hash.h"
|
||||
#include "zeek/IPAddr.h"
|
||||
#include "zeek/RE.h"
|
||||
#include "zeek/Reporter.h"
|
||||
|
|
|
@ -524,6 +524,8 @@ void ScriptFunc::CreateCaptures(std::unique_ptr<std::vector<ZVal>> cvec) {
|
|||
}
|
||||
}
|
||||
|
||||
void ScriptFunc::SetCapturesVec(std::unique_ptr<std::vector<ZVal>> cv) { captures_vec = std::move(cv); }
|
||||
|
||||
void ScriptFunc::SetCaptures(Frame* f) {
|
||||
const auto& captures = type->GetCaptures();
|
||||
ASSERT(captures);
|
||||
|
|
13
src/Func.h
13
src/Func.h
|
@ -11,9 +11,16 @@
|
|||
|
||||
#include "zeek/Obj.h"
|
||||
#include "zeek/Scope.h"
|
||||
#include "zeek/Stmt.h"
|
||||
#include "zeek/StmtBase.h"
|
||||
#include "zeek/StmtEnums.h"
|
||||
#include "zeek/TraverseTypes.h"
|
||||
#include "zeek/Type.h" /* for function_flavor */
|
||||
#include "zeek/Type.h" /* for FunctionFlavor */
|
||||
|
||||
// This is needed in order to chain-include ZVal.h, which is what's
|
||||
// actually needed by Func.h. If you don't include Val.h along with
|
||||
// ZVal.h, Windows fails to build because of the forward declarations
|
||||
// in ZVal.h.
|
||||
#include "zeek/Val.h"
|
||||
#include "zeek/ZeekArgs.h"
|
||||
#include "zeek/ZeekList.h"
|
||||
|
||||
|
@ -223,7 +230,7 @@ public:
|
|||
*
|
||||
* @param cv The value used for captures_vec.
|
||||
*/
|
||||
void SetCapturesVec(std::unique_ptr<std::vector<ZVal>> cv) { captures_vec = std::move(cv); }
|
||||
void SetCapturesVec(std::unique_ptr<std::vector<ZVal>> cv);
|
||||
|
||||
// Same definition as in Frame.h.
|
||||
using OffsetMap = std::unordered_map<std::string, int>;
|
||||
|
|
|
@ -6,6 +6,7 @@
|
|||
|
||||
#include "zeek/Attr.h"
|
||||
#include "zeek/Desc.h"
|
||||
#include "zeek/Dict.h"
|
||||
#include "zeek/EventRegistry.h"
|
||||
#include "zeek/Expr.h"
|
||||
#include "zeek/File.h"
|
||||
|
|
|
@ -8,6 +8,7 @@
|
|||
|
||||
#include "zeek/Conn.h"
|
||||
#include "zeek/DNS_Mgr.h"
|
||||
#include "zeek/Dict.h"
|
||||
#include "zeek/Event.h"
|
||||
#include "zeek/File.h"
|
||||
#include "zeek/Func.h"
|
||||
|
|
|
@ -1,3 +1,7 @@
|
|||
%extern{
|
||||
#include "zeek/Dict.h"
|
||||
%}
|
||||
|
||||
refine connection SMB_Conn += {
|
||||
function proc_smb1_nt_create_andx_request(header: SMB_Header, val: SMB1_nt_create_andx_request): bool
|
||||
%{
|
||||
|
|
|
@ -1,3 +1,7 @@
|
|||
%extern{
|
||||
#include "zeek/Dict.h"
|
||||
%}
|
||||
|
||||
refine connection SMB_Conn += {
|
||||
|
||||
function proc_smb2_create_request(h: SMB2_Header, val: SMB2_create_request): bool
|
||||
|
|
|
@ -5,6 +5,7 @@
|
|||
#include <broker/error.hh>
|
||||
|
||||
#include "zeek/Desc.h"
|
||||
#include "zeek/Dict.h"
|
||||
#include "zeek/File.h"
|
||||
#include "zeek/Func.h"
|
||||
#include "zeek/ID.h"
|
||||
|
|
|
@ -7,6 +7,7 @@
|
|||
|
||||
#include "zeek/CompHash.h"
|
||||
#include "zeek/Desc.h"
|
||||
#include "zeek/Dict.h"
|
||||
#include "zeek/Event.h"
|
||||
#include "zeek/EventHandler.h"
|
||||
#include "zeek/Expr.h"
|
||||
|
|
|
@ -8,6 +8,7 @@
|
|||
#include <utility>
|
||||
|
||||
#include "zeek/Desc.h"
|
||||
#include "zeek/Dict.h"
|
||||
#include "zeek/Event.h"
|
||||
#include "zeek/EventHandler.h"
|
||||
#include "zeek/File.h"
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
#include "zeek/Dict.h"
|
||||
#include "zeek/Val.h"
|
||||
#include "zeek/ZeekString.h"
|
||||
#include "zeek/script_opt/ZAM/ZInstAux.h"
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
|
||||
#include "zeek/Conn.h"
|
||||
#include "zeek/Desc.h"
|
||||
#include "zeek/Dict.h"
|
||||
#include "zeek/EventHandler.h"
|
||||
#include "zeek/File.h"
|
||||
#include "zeek/Frame.h"
|
||||
|
|
|
@ -26,6 +26,7 @@ extern "C" {
|
|||
}
|
||||
|
||||
#include "zeek/DebugLogger.h"
|
||||
#include "zeek/Dict.h"
|
||||
#include "zeek/Event.h"
|
||||
#include "zeek/EventHandler.h"
|
||||
#include "zeek/ID.h"
|
||||
|
|
|
@ -43,6 +43,7 @@
|
|||
#include "zeek/Scope.h"
|
||||
#include "zeek/ScriptCoverageManager.h"
|
||||
#include "zeek/Stats.h"
|
||||
#include "zeek/Stmt.h"
|
||||
#include "zeek/Timer.h"
|
||||
#include "zeek/Traverse.h"
|
||||
#include "zeek/Trigger.h"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue