This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Containers: assignment, construction from
- To: "'gcc at gcc dot gnu dot org'" <gcc at gcc dot gnu dot org>
- Subject: Containers: assignment, construction from
- From: Anjul Srivastava <anjul dot srivastava at sanchez dot com>
- Date: Thu, 17 Feb 2000 17:38:59 -0500
I thought you could construct a container from another, as also assign one
to the other. Is the following program not legal C++? Or is the gcc
implementation of the STL incomplete?
Thanks,
Anjul.
#include <vector>
#include <list>
int main()
{
list< int > m;
m.push_back(3);
vector< int > v(m);
return 0;
}