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

@ -588,7 +588,10 @@ Val* Value::ValueToVal(const std::string& source, const Value* val, bool& have_e
auto v = make_intrusive<VectorVal>(std::move(vt));
for ( int j = 0; j < val->val.vector_val.size; j++ )
v->Assign(j, ValueToVal(source, val->val.vector_val.vals[j], have_error));
{
auto el = ValueToVal(source, val->val.vector_val.vals[j], have_error);
v->Assign(j, {AdoptRef{}, el});
}
return v.release();
}