diff options
author | jan.reininghaus <jan.reininghaus@8e3bb3c2-eed4-f18f-5264-0b6c94e6926d> | 2013-04-23 15:27:22 +0000 |
---|---|---|
committer | jan.reininghaus <jan.reininghaus@8e3bb3c2-eed4-f18f-5264-0b6c94e6926d> | 2013-04-23 15:27:22 +0000 |
commit | 7b96eb822cf02b5d92905f0ab732e977b4dd0e7c (patch) | |
tree | 8139201abf284c2b202600dc3028fe05bd93a49e /include/phat/representations/vector_set.h | |
parent | 62c12d494efce198271d4a6f2ac74c6810d4bbfa (diff) |
vector_set cleanup
git-svn-id: https://phat.googlecode.com/svn/trunk@41 8e3bb3c2-eed4-f18f-5264-0b6c94e6926d
Diffstat (limited to 'include/phat/representations/vector_set.h')
-rw-r--r-- | include/phat/representations/vector_set.h | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/include/phat/representations/vector_set.h b/include/phat/representations/vector_set.h index 2ce0c56..dadf1b3 100644 --- a/include/phat/representations/vector_set.h +++ b/include/phat/representations/vector_set.h @@ -51,7 +51,6 @@ namespace phat { col.clear(); col.reserve( matrix[idx].size() ); std::copy (matrix[idx].begin(), matrix[idx].end(), std::back_inserter(col) ); - std::sort( col.begin(), col.end() ); } void _set_col( index idx, const column& col ) { matrix[ idx ].clear(); @@ -85,11 +84,8 @@ namespace phat { // adds column 'source' to column 'target' void _add_to( index source, index target ) { - internal_column& source_col = matrix[ source ]; - for( internal_column::const_iterator source_it = source_col.begin(); - source_it != source_col.end(); source_it++ ) { - _toggle(target, *source_it); - } + for( internal_column::iterator it = matrix[ source ].begin(); it != matrix[ source ].end(); it++ ) + _toggle( target, *it ); } //// toggles given index pair |