Changeset 115:3d9681ef6116 in lemon-0.x for src/work/alpar
- Timestamp:
- 02/22/04 13:51:34 (21 years ago)
- Branch:
- default
- Phase:
- public
- Convert:
- svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@150
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/work/alpar/smart_graph.h
r108 r115 283 283 { 284 284 //FIXME: What if there are empty Id's? 285 //FIXME: Can I use 'this' in a constructor? 285 286 G->dyn_node_maps.push_back(this); 286 287 } … … 291 292 for(i=G->dyn_node_maps.begin(); 292 293 i!=G->dyn_node_maps.end() && *i!=this; ++i) ; 293 if(*i==this) G->dyn_node_maps.erase(i); //FIXME: Way too slow... 294 //if(*i==this) G->dyn_node_maps.erase(i); //FIXME: Way too slow... 295 //A better way to do that: (Is this really important?) 296 if(*i==this) { 297 G->dyn_node_maps[i]=G->dyn_node_maps.back; 298 G->dyn_node_maps.pop_back(); 299 } 294 300 } 295 301 } … … 325 331 { 326 332 //FIXME: What if there are empty Id's? 327 //FIXME: Can I do that? :333 //FIXME: Can I use 'this' in a constructor? 328 334 G->dyn_edge_maps.push_back(this); 329 335 } … … 334 340 for(i=G->dyn_edge_maps.begin(); 335 341 i!=G->dyn_edge_maps.end() && *i!=this; ++i) ; 336 if(*i==this) G->dyn_edge_maps.erase(i); //FIXME: Way too slow... 342 //if(*i==this) G->dyn_edge_maps.erase(i); //Way too slow... 343 //A better way to do that: (Is this really important?) 344 if(*i==this) { 345 G->dyn_edge_maps[i]=G->dyn_edge_maps.back; 346 G->dyn_edge_maps.pop_back(); 347 } 337 348 } 338 349 } 339 350 340 351 void add(const EdgeIt k) 341 352 {
Note: See TracChangeset
for help on using the changeset viewer.