Since boost::scoped_ptr doesn't work with [] indexing operator, I am trying to do a workaround like this
{
boost::scoped_ptr<float> data_ptr;
float *data = new float(SIZE);
data_ptr.reset(data);
...
}
Will the array be freed later on? Is there a better way to do this?