Boost logo

Glas :

Re: [glas] unallocated fill

From: Karl Meerbergen (Karl.Meerbergen_at_[hidden])
Date: 2005-10-03 08:47:21


Kresimir Fresl wrote:

>Karl Meerbergen wrote:
>
>
>
>>Neal Becker wrote:
>>
>>
>
>[...]
>
>
>>>Thanks. The free function is fine. I suggested this because it is consistent
>>>with STL, so maybe more familiar.
>>>
>>>
>
>
>
>>Consistency with STL is a strong argument though. So, perhaps we should
>>consider it for a dense_vector. For a sparse_vector, it does not make
>>sense, I suppose.
>>
>>
>
>
>
>>To what extent do we want to be consistent with STL? I suppose the
>>answer is very personal.
>>
>>
>
>I think that internal consistency is more important. So, if
>sparse_vector does not have initializing constructor, than
>dense_vector should not have it, too. But, it's just my
>opinion.
>
>Regards,
>
>fres
>
>

I agree with this viewpoint. I suggest that for the time being, we add a
free function
fill( v, value ) ;
If there is a strong request for a constructor, we can still do that for
dense_vector().

Karl