This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
at()
- To: gcc-bugs at gcc dot gnu dot org
- Subject: at()
- From: Takanori YOSHIKOSHI <tyoshiko at sci dot osaka-cu dot ac dot jp>
- Date: Fri, 25 Feb 2000 20:48:06 +0900
Hi,
I'm using gcc 2.95.2 on Linux 2.0.36. The following C++
program cannot be compiled.
// tmp.cc
#include <vector>
using namespace std;
int main()
{
int a[] = {1, 2, 3};
vector<int> v(a, a + 3);
v.at(2);
return 0;
}
$ g++ -v
Reading specs from /usr/local/lib/gcc-lib/i686-pc-linux-gnu/2.95.2/specs
gcc version 2.95.2 19991024 (release)
$ g++ tmp.cc
tmp.cc: In function `int main()':
tmp.cc:9: no matching function for call to `vector<int,allocator<int> >::at (int)'
Is that a known bug?
Best regards,
--
Taka Yoshikoshi
tyoshiko@sci.osaka-cu.ac.jp