Deprecate TypeDecl::FindAttr(), replace with GetAttr()

This commit is contained in:
Jon Siwek 2020-05-26 15:41:25 -07:00
parent 5fc78a548c
commit e365105872
6 changed files with 26 additions and 23 deletions

View file

@ -242,7 +242,7 @@ bool Manager::CreateStream(EnumVal* id, RecordVal* sval)
for ( int i = 0; i < columns->NumFields(); i++ )
{
if ( ! (columns->FieldDecl(i)->FindAttr(ATTR_LOG)) )
if ( ! (columns->FieldDecl(i)->GetAttr(ATTR_LOG)) )
continue;
if ( ! threading::Value::IsCompatibleType(columns->GetFieldType(i).get()) )
@ -410,7 +410,7 @@ bool Manager::TraverseRecord(Stream* stream, Filter* filter, RecordType* rt,
const auto& t = rtype->GetFieldType(i);
// Ignore if &log not specified.
if ( ! rtype->FieldDecl(i)->FindAttr(ATTR_LOG) )
if ( ! rtype->FieldDecl(i)->GetAttr(ATTR_LOG) )
continue;
list<int> new_indices = indices;
@ -516,7 +516,7 @@ bool Manager::TraverseRecord(Stream* stream, Filter* filter, RecordType* rt,
else if ( t->Tag() == TYPE_VECTOR )
st = t->AsVectorType()->Yield()->Tag();
bool optional = rtype->FieldDecl(i)->FindAttr(ATTR_OPTIONAL);
bool optional = (bool)rtype->FieldDecl(i)->GetAttr(ATTR_OPTIONAL);
filter->fields[filter->num_fields - 1] = new threading::Field(new_path.c_str(), nullptr, t->Tag(), st, optional);
}