Vector: at() member function

Anjul Srivastava anjul.srivastava@sanchez.com
Fri Jan 21 10:33:00 GMT 2000


Which would be the correct list to direct the following question:

Am I doing something wrong here?

sparky%cat vector.c
#include <vector>

int main(void);

int main(void)
{
    vector<int> v(10);
    v.at(3)=7;

    return 0;
}
sparky%g++ vector.c
vector.c: In function `int main()':
vector.c:8: no matching function for call to
`vector<int,__default_alloc_template<false,0> >::at (int)'
sparky%g++ -v
Reading specs from /usr/local/lib/gcc-lib/sparc-sun-solaris2.6/2.8.1/specs
gcc version 2.8.1
sparky%



More information about the Gcc-bugs mailing list