mirror of
https://github.com/boostorg/container.git
synced 2026-07-11 12:20:53 +02:00
Fixes #221 ("flat_set and friends should offer a const sequence_type& sequence() const method (...)")
This commit is contained in:
+12
-4
@@ -306,7 +306,7 @@ bool flat_tree_extract_adopt_test()
|
||||
fmap.emplace(static_cast<int>(i), -static_cast<int>(i));
|
||||
}
|
||||
|
||||
flat_map<int, int> fmap_copy(fmap);
|
||||
const flat_map<int, int> fmap_copy(fmap);
|
||||
flat_map<int, int>::sequence_type seq(fmap.extract_sequence());
|
||||
if(!fmap.empty())
|
||||
return false;
|
||||
@@ -318,6 +318,8 @@ bool flat_tree_extract_adopt_test()
|
||||
fmap.adopt_sequence(boost::move(seq));
|
||||
if(!CheckEqualContainers(fmap, fmap_copy))
|
||||
return false;
|
||||
if (!CheckEqualContainers(fmap.sequence(), fmap_copy.sequence()))
|
||||
return false;
|
||||
}
|
||||
|
||||
//extract/adopt map, ordered_unique_range
|
||||
@@ -329,7 +331,7 @@ bool flat_tree_extract_adopt_test()
|
||||
fmap.emplace(static_cast<int>(i), -static_cast<int>(i));
|
||||
}
|
||||
|
||||
flat_map<int, int> fmap_copy(fmap);
|
||||
const flat_map<int, int> fmap_copy(fmap);
|
||||
flat_map<int, int>::sequence_type seq(fmap.extract_sequence());
|
||||
if(!fmap.empty())
|
||||
return false;
|
||||
@@ -339,6 +341,8 @@ bool flat_tree_extract_adopt_test()
|
||||
fmap.adopt_sequence(ordered_unique_range, boost::move(seq));
|
||||
if(!CheckEqualContainers(fmap, fmap_copy))
|
||||
return false;
|
||||
if (!CheckEqualContainers(fmap.sequence(), fmap_copy.sequence()))
|
||||
return false;
|
||||
}
|
||||
|
||||
//extract/adopt multimap
|
||||
@@ -351,7 +355,7 @@ bool flat_tree_extract_adopt_test()
|
||||
fmmap.emplace(static_cast<int>(i), -static_cast<int>(i));
|
||||
}
|
||||
|
||||
flat_multimap<int, int> fmmap_copy(fmmap);
|
||||
const flat_multimap<int, int> fmmap_copy(fmmap);
|
||||
flat_multimap<int, int>::sequence_type seq(fmmap.extract_sequence());
|
||||
if(!fmmap.empty())
|
||||
return false;
|
||||
@@ -362,6 +366,8 @@ bool flat_tree_extract_adopt_test()
|
||||
fmmap.adopt_sequence(boost::move(seq));
|
||||
if(!CheckEqualContainers(fmmap, fmmap_copy))
|
||||
return false;
|
||||
if (!CheckEqualContainers(fmmap.sequence(), fmmap_copy.sequence()))
|
||||
return false;
|
||||
}
|
||||
|
||||
//extract/adopt multimap, ordered_range
|
||||
@@ -374,7 +380,7 @@ bool flat_tree_extract_adopt_test()
|
||||
fmmap.emplace(static_cast<int>(i), -static_cast<int>(i));
|
||||
}
|
||||
|
||||
flat_multimap<int, int> fmmap_copy(fmmap);
|
||||
const flat_multimap<int, int> fmmap_copy(fmmap);
|
||||
flat_multimap<int, int>::sequence_type seq(fmmap.extract_sequence());
|
||||
if(!fmmap.empty())
|
||||
return false;
|
||||
@@ -384,6 +390,8 @@ bool flat_tree_extract_adopt_test()
|
||||
fmmap.adopt_sequence(ordered_range, boost::move(seq));
|
||||
if(!CheckEqualContainers(fmmap, fmmap_copy))
|
||||
return false;
|
||||
if (!CheckEqualContainers(fmmap.sequence(), fmmap_copy.sequence()))
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
|
||||
Reference in New Issue
Block a user