SET &added, SET &common, SET &old_common, SET &deleted ) {
FileDataNameCmp cmp;
- set_difference( current.begin(), current.end(),
- old.begin(), old.end(),
- inserter( added, added.begin() ),
- cmp );
-
- set_difference( old.begin(), old.end(),
- current.begin(), current.end(),
- inserter( deleted, deleted.begin() ),
- cmp );
-
- set_union( current.begin(), current.end(),
- old.begin(), old.end(),
- inserter( common, common.begin() ),
- cmp );
-
- set_union( old.begin(), old.end(),
- common.begin(), common.end(),
- inserter( old_common, old_common.begin() ),
- cmp );
+ set_difference( current.begin(), current.end(),
+ old.begin(), old.end(),
+ inserter( added, added.begin() ),
+ cmp );
+
+ set_difference( old.begin(), old.end(),
+ current.begin(), current.end(),
+ inserter( deleted, deleted.begin() ),
+ cmp );
+
+ set_intersection( current.begin(), current.end(),
+ old.begin(), old.end(),
+ inserter( common, common.begin() ),
+ cmp );
+
+ set_intersection( old.begin(), old.end(),
+ common.begin(), common.end(),
+ inserter( old_common, old_common.begin() ),
+ cmp );
}
template<class INT>