Switch AnalyOpt::only_func to optional<string>

Nothing of consequence; may help express meaning and memory management.
This commit is contained in:
Jon Siwek 2021-01-13 13:19:46 -08:00
parent 48da8b7d66
commit 81fa7f7e3d
3 changed files with 11 additions and 4 deletions

View file

@ -4,6 +4,9 @@
#pragma once
#include <string>
#include <optional>
#include "zeek/Func.h"
#include "zeek/Expr.h"
#include "zeek/Scope.h"
@ -25,7 +28,7 @@ struct AnalyOpt {
bool dump_xform = false;
// If non-nil, then only analyze the given function/event/hook.
const char* only_func = nullptr;
std::optional<std::string> only_func;
// If true, do global inlining.
bool inliner = false;