On 2/4/02 9:03 AM, "Duane Murphy"
I would be interested in finding a class that is somewhere between allocating my own buffers and vector<>. Low overhead for simple allocations; no resizing or growing. Even in this case, in order to support iterator semantics the size is going to be needed.
There's a class boost::array that will sometimes meet your requirements. There's another proposed class that will probably show up in a future version of Boost called boost::fixed_capacity_vector that might also meet your requirements. A boost::scoped_array or boost::shared_array is occasionally useful, but not often. But be wary of overestimating the importance of std::vector's low overhead. It's often quite affordable, and not having a fixed capacity limit can be a valuable feature that can help you avoid buffer overrun problems. -- Darin