mirror of
https://github.com/zeek/zeek.git
synced 2025-10-09 18:18:19 +00:00
Type: use class IntrusivePtr in IndexType
This commit is contained in:
parent
674e141a15
commit
de0289125b
8 changed files with 45 additions and 77 deletions
|
@ -1234,9 +1234,9 @@ TableVal* ListVal::ConvertToSet() const
|
|||
if ( tag == TYPE_ANY )
|
||||
Internal("conversion of heterogeneous list to set");
|
||||
|
||||
TypeList* set_index = new TypeList(type->AsTypeList()->PureType());
|
||||
auto set_index = make_intrusive<TypeList>(type->AsTypeList()->PureType());
|
||||
set_index->Append(base_type(tag));
|
||||
auto s = make_intrusive<SetType>(set_index, nullptr);
|
||||
auto s = make_intrusive<SetType>(std::move(set_index), nullptr);
|
||||
TableVal* t = new TableVal(std::move(s));
|
||||
|
||||
for ( const auto& val : vals )
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue