$include_dir="/home/hyper-archives/boost/include"; include("$include_dir/msg-header.inc") ?>
From: Jon Jagger (Jon.Jagger_at_[hidden])
Date: 2000-01-04 18:30:47
> > >Darin Adler wrote:
> > >THIS is an important design issue. Unless somebody has a solution to
> > >fit
> > >both needs, we have to decide between what I would call an
> > > - array wrapper and
> > > - an STL container similar to vector with static size.
> > >Or may be we introduce both.
> > >
> > >However, if we introduce both, then we need a name for both
> > >(I' suggest array for the array wrapper and ???vector for the
> > latter).
> > >
> > >Opinions, please!
Ok. Here's mine. Schools of naming thought...
/1/ array and array_adaptor/array_wrapper
Nice because the implementation uses a raw array.
The use of 'array' is a strong in "array_adaptor/array_wrapper" (where the
adapted raw array is visible) but weaker for "array" (where the contained
raw array is not so visible).
/2/ fixed_vector and fixed_vector_adaptor/fixed_vector_wrapper
Nice because the use of vector hints at the container model. And conversely
the use of 'vector' is weak in "fixed_vector_adaptor/fixed_vector_wrapper"
(where the adapted array is visible) but strong for "fixed_vector" (where
the contained raw array is not so visible). Also nice because it doesn't
use the name array, which I think is best left as the name of a raw C
array.
In summary, using 'array' focuses on the implementation and using 'vector'
focuses on the interface.
My preferece is for /2/
And I prefer adaptor to wrapper.
$0.02
Jon Jagger
We have one mouth, two eyes, and two ears and we should use them in
proportion.