Topic: Container resize parameter
Author: "Ed Brey" <brey@afd.mke.etn.com>
Date: 1999/09/25 Raw View
For the standard sequences, why does resize take type T by value whereas all
other functions that take type T take T by reference to constant? e.g. from
23.2.4,2:
class vector
{
explicit vector(size_type n, const T& value = T()), const Allocator& =
Allocator());
void push_back(const T& x);
void resize(size_type sz, T c = T());
};
---
[ comp.std.c++ is moderated. To submit articles, try just posting with ]
[ your news-reader. If that fails, use mailto:std-c++@ncar.ucar.edu ]
[ --- Please see the FAQ before posting. --- ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html ]