mirror of
https://github.com/zeek/zeek.git
synced 2025-10-11 02:58:20 +00:00
Remove deprecated MemoryAllocation() methods and related code
This commit is contained in:
parent
d3169e48c0
commit
70e63d4749
39 changed files with 15 additions and 659 deletions
20
src/Type.cc
20
src/Type.cc
|
@ -269,11 +269,6 @@ void Type::SetError()
|
|||
tag = TYPE_ERROR;
|
||||
}
|
||||
|
||||
unsigned int Type::MemoryAllocation() const
|
||||
{
|
||||
return padded_sizeof(*this);
|
||||
}
|
||||
|
||||
detail::TraversalCode Type::Traverse(detail::TraversalCallback* cb) const
|
||||
{
|
||||
auto tc = cb->PreType(this);
|
||||
|
@ -334,21 +329,6 @@ void TypeList::DoDescribe(ODesc* d) const
|
|||
}
|
||||
}
|
||||
|
||||
unsigned int TypeList::MemoryAllocation() const
|
||||
{
|
||||
unsigned int size = 0;
|
||||
|
||||
#pragma GCC diagnostic push
|
||||
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
|
||||
for ( const auto& t : types )
|
||||
size += t->MemoryAllocation();
|
||||
|
||||
size += util::pad_size(types.capacity() * sizeof(decltype(types)::value_type));
|
||||
|
||||
return Type::MemoryAllocation() + padded_sizeof(*this) - padded_sizeof(Type) + size;
|
||||
#pragma GCC diagnostic pop
|
||||
}
|
||||
|
||||
detail::TraversalCode TypeList::Traverse(detail::TraversalCallback* cb) const
|
||||
{
|
||||
auto tc = cb->PreType(this);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue