Migrate Tag classes to use IntrusivePtr

Deprecates various methods that previously took raw pointers
This commit is contained in:
Jon Siwek 2020-05-05 17:10:34 -07:00
parent b096e552d3
commit 1abed4fd4c
20 changed files with 174 additions and 85 deletions

View file

@ -68,7 +68,8 @@ function Files::__stop%(file_id: string%): bool
## :zeek:see:`Files::analyzer_name`.
function Files::__analyzer_name%(tag: Files::Tag%) : string
%{
return make_intrusive<StringVal>(file_mgr->GetComponentName(tag));
const auto& n = file_mgr->GetComponentName(IntrusivePtr{NewRef{}, tag->AsEnumVal()});
return make_intrusive<StringVal>(n);
%}
## :zeek:see:`Files::file_exists`.