vector

R

rsforster

I was wondering why Visual Studio is not recognizing my vector
declarations properly.

I enter the following code :

#include <vector>

....


class whatever {

....

vector<aule_gl_window *> * windows;

....

}


and it sometimes gives me an error like :

Missing semicolon after 'vector'

It does not seem to recognize anything after the identifier "vevtor"


Robin
 
M

mlimber

I was wondering why Visual Studio is not recognizing my vector
declarations properly.

I enter the following code :

#include <vector>

...


class whatever {

...

vector<aule_gl_window *> * windows;

Try std::vector. Are you sure you want a pointer to a vector?
...

}


and it sometimes gives me an error like :

Missing semicolon after 'vector'

It does not seem to recognize anything after the identifier "vevtor"


Robin

Cheers! --M
 
R

rsforster

mlimber said:
Try std::vector. Are you sure you want a pointer to a vector?

I tried that and it does not work.

As for the pointer, this was my first big C++ project and there are a
few faux pas like this in my code.
 
R

rossum

I was wondering why Visual Studio is not recognizing my vector
declarations properly.

I enter the following code :

#include <vector>

...


class whatever {

...

vector<aule_gl_window *> * windows;

...

}


and it sometimes gives me an error like :

Missing semicolon after 'vector'

It does not seem to recognize anything after the identifier "vevtor"


Robin

Have you tried changing the name of your variable "windows" which
might be doing something strange to the MS compiler?

Failing that, can you get
std::vector<int> intVec; to compile?

how about
std::vector<int*> intPvec; ?

rossum
 
R

rsforster

Have you tried changing the name of your variable "windows" which
might be doing something strange to the MS compiler?

Failing that, can you get
std::vector<int> intVec; to compile?

how about
std::vector<int*> intPvec; ?

rossum

I'll give it a shot.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,142
Messages
2,570,819
Members
47,367
Latest member
mahdiharooniir

Latest Threads

Top