I have these typedefs:
typedef pair<k2Base, list<v2Base>> shuffled_pair;
typedef list<shuffled_pair> shuffled_list;
and this function:
shuffled_pair getItem(unsigned int index){
return this->_items[index];
}
where this->_items
is of type shuffled_list
as declared in the typedef.
I get this error from the compiler:
Type 'const shuffled_list' (aka 'const list<pair<k2Base, list<v2Base> > >') does not provide a subscript operator
But the type is basically a list type, so what is the problem?