So that is the error that I am getting. I know what it means and I slightly have an idea of why I am getting it, but I do not know how to correct it.
Let me introduce the players in this scene.
So I have an Instruction class and shared pointers to them called InstructionPtr. Then I have a ReservationStation class that contains an InstructionPtr through composition and shared pointers to ReservationStations called RSPtr. I then have a RSPtr list class and finally an OOOQueue class that contains two RSPtr lists. I am getting this error at the lineCode:class Instruction { ... }; typedef boost::shared_ptr<Instruction> InstructionPtr; class ReservationStation { ... public: InstructionPtr instr; ... }; typedef boost::shared_ptr<ReservationStation> RSPtr; class ReservationStationList : private std::list<RSPtr> { public: void push_back(InstructionPtr instr); void push_back(RSPtr rs); ..... private: using std::list<RSPtr>::push_back; ... } class OOOQueue { public: ... void update() { for (ReservationStationList::iterator p = list.begin(); p != list.end(); ++p) { if ((*p)->ready()) ready_list.push_back(*p); } ready_list.sort(); } private: ReservationStationList list; ReservationStationList ready_list; }
I am intending to call the publicly definedCode:ready_list.push_back(*p);
version.Code:void push_back(RSPtr rs);



LinkBack URL
About LinkBacks



ush_back then I am calling the scope of std::list and not ReservationStationList. The effect of that is that a new list will be created, not the calling object. Is that correct?