forked from boostorg/move
Git Issue #15: Incorrect merge in adaptive_merge when the number of unique items is limited
This commit is contained in:
@@ -2437,7 +2437,8 @@ void adaptive_merge_impl
|
||||
|
||||
//Not the minimum number of keys is not available on the first range, so fallback to rotations
|
||||
if(collected != to_collect && collected < 4){
|
||||
merge_bufferless(first, first+len1, first+len1+len2, comp);
|
||||
merge_bufferless(first, first+collected, first+len1, comp);
|
||||
merge_bufferless(first, first + len1, first + len1 + len2, comp);
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user