Deprecate VectorVal::Assign methods taking raw Val*

And adapt usages to pass in to alternate method taking IntrusivePtr
This commit is contained in:
Jon Siwek 2020-05-21 15:31:04 -07:00
parent 2cbf36721c
commit de1e3d7d6d
15 changed files with 77 additions and 54 deletions

View file

@ -2275,7 +2275,10 @@ Val* Manager::ValueToVal(const Stream* i, const Value* val, BroType* request_typ
auto v = make_intrusive<VectorVal>(std::move(vt));
for ( int j = 0; j < val->val.vector_val.size; j++ )
v->Assign(j, ValueToVal(i, val->val.vector_val.vals[j], type.get(), have_error));
{
auto el = ValueToVal(i, val->val.vector_val.vals[j], type.get(), have_error);
v->Assign(j, {AdoptRef{}, el});
}
return v.release();
}