- Fix Dynamic* constructor to add them objects into the correct
vector - Split push_back in constructors on two lines so the compiler warns us if returned vectors are temporary objects, or do not match the expected type git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@745 3ecf2c5c-341e-0410-92b4-d18e462d057c
This commit is contained in:
parent
301775debd
commit
0e79b163f3
4 changed files with 15 additions and 15 deletions
|
@ -35,7 +35,10 @@ DynamicSubRequest::DynamicSubRequest(StaticSubRequest* core,
|
|||
_queue_position(-1)
|
||||
{
|
||||
assert(core != NULL);
|
||||
owner->get_subrequests().push_back(this);
|
||||
// Leave this line: it helps us with a compiler warning if
|
||||
// the get_dynamic* method signature changes:
|
||||
std::vector<DynamicSubRequest*>& siblings = owner->get_dynamic_subrequests();
|
||||
siblings.push_back(this);
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue