deque does not work

I am trying to replace some vector lists of my program with deques. Unfortunatelly I always get an error and I don’t really know what is wrong.

if I replace:

vector<int> red;  


deque<int> red;  

I get the error:
error: ISO C++ forbids declaration of ‘deque’ with no type

I tried alot of different things to get it to run but I failed. Does anybody have a working piece of code for OF using deques?

I think you just need to include deque:

#include <deque>  

vector is already included in oF but deque is not

I also did that. remains the same.

Edit: okay, I am too tired. I put it in between #ifdef statement :>

sorry deque.h, that error seems the typical thing with non including the headers, the compiler doesn’t find the type so it “thinks” deque is a variable with no type behind…

I’m trying with deque.h and it works, but perhaps in linux is diferent

What arturo said plus make sure your are using the “std” namespace. Also this should be default in OF but in some situations you have to add “using std;” to the file in question. If you are unsure just write “std::deque red;” instead.