forked from boostorg/unordered
Add BOOST_NOEXCEPT to unordered container methods.
I haven't done the iterators yet. [SVN r84253]
This commit is contained in:
@ -178,53 +178,53 @@ namespace unordered
|
|||||||
unordered_map& operator=(std::initializer_list<value_type>);
|
unordered_map& operator=(std::initializer_list<value_type>);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
allocator_type get_allocator() const
|
allocator_type get_allocator() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.node_alloc();
|
return table_.node_alloc();
|
||||||
}
|
}
|
||||||
|
|
||||||
// size and capacity
|
// size and capacity
|
||||||
|
|
||||||
bool empty() const
|
bool empty() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.size_ == 0;
|
return table_.size_ == 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
size_type size() const
|
size_type size() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.size_;
|
return table_.size_;
|
||||||
}
|
}
|
||||||
|
|
||||||
size_type max_size() const;
|
size_type max_size() const BOOST_NOEXCEPT;
|
||||||
|
|
||||||
// iterators
|
// iterators
|
||||||
|
|
||||||
iterator begin()
|
iterator begin() BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.begin();
|
return table_.begin();
|
||||||
}
|
}
|
||||||
|
|
||||||
const_iterator begin() const
|
const_iterator begin() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.begin();
|
return table_.begin();
|
||||||
}
|
}
|
||||||
|
|
||||||
iterator end()
|
iterator end() BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return iterator();
|
return iterator();
|
||||||
}
|
}
|
||||||
|
|
||||||
const_iterator end() const
|
const_iterator end() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return const_iterator();
|
return const_iterator();
|
||||||
}
|
}
|
||||||
|
|
||||||
const_iterator cbegin() const
|
const_iterator cbegin() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.begin();
|
return table_.begin();
|
||||||
}
|
}
|
||||||
|
|
||||||
const_iterator cend() const
|
const_iterator cend() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return const_iterator();
|
return const_iterator();
|
||||||
}
|
}
|
||||||
@ -449,12 +449,12 @@ namespace unordered
|
|||||||
|
|
||||||
// bucket interface
|
// bucket interface
|
||||||
|
|
||||||
size_type bucket_count() const
|
size_type bucket_count() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.bucket_count_;
|
return table_.bucket_count_;
|
||||||
}
|
}
|
||||||
|
|
||||||
size_type max_bucket_count() const
|
size_type max_bucket_count() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.max_bucket_count();
|
return table_.max_bucket_count();
|
||||||
}
|
}
|
||||||
@ -501,13 +501,13 @@ namespace unordered
|
|||||||
|
|
||||||
// hash policy
|
// hash policy
|
||||||
|
|
||||||
float max_load_factor() const
|
float max_load_factor() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.mlf_;
|
return table_.mlf_;
|
||||||
}
|
}
|
||||||
|
|
||||||
float load_factor() const;
|
float load_factor() const BOOST_NOEXCEPT;
|
||||||
void max_load_factor(float);
|
void max_load_factor(float) BOOST_NOEXCEPT;
|
||||||
void rehash(size_type);
|
void rehash(size_type);
|
||||||
void reserve(size_type);
|
void reserve(size_type);
|
||||||
|
|
||||||
@ -660,53 +660,53 @@ namespace unordered
|
|||||||
unordered_multimap& operator=(std::initializer_list<value_type>);
|
unordered_multimap& operator=(std::initializer_list<value_type>);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
allocator_type get_allocator() const
|
allocator_type get_allocator() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.node_alloc();
|
return table_.node_alloc();
|
||||||
}
|
}
|
||||||
|
|
||||||
// size and capacity
|
// size and capacity
|
||||||
|
|
||||||
bool empty() const
|
bool empty() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.size_ == 0;
|
return table_.size_ == 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
size_type size() const
|
size_type size() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.size_;
|
return table_.size_;
|
||||||
}
|
}
|
||||||
|
|
||||||
size_type max_size() const;
|
size_type max_size() const BOOST_NOEXCEPT;
|
||||||
|
|
||||||
// iterators
|
// iterators
|
||||||
|
|
||||||
iterator begin()
|
iterator begin() BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.begin();
|
return table_.begin();
|
||||||
}
|
}
|
||||||
|
|
||||||
const_iterator begin() const
|
const_iterator begin() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.begin();
|
return table_.begin();
|
||||||
}
|
}
|
||||||
|
|
||||||
iterator end()
|
iterator end() BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return iterator();
|
return iterator();
|
||||||
}
|
}
|
||||||
|
|
||||||
const_iterator end() const
|
const_iterator end() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return const_iterator();
|
return const_iterator();
|
||||||
}
|
}
|
||||||
|
|
||||||
const_iterator cbegin() const
|
const_iterator cbegin() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.begin();
|
return table_.begin();
|
||||||
}
|
}
|
||||||
|
|
||||||
const_iterator cend() const
|
const_iterator cend() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return const_iterator();
|
return const_iterator();
|
||||||
}
|
}
|
||||||
@ -927,12 +927,12 @@ namespace unordered
|
|||||||
|
|
||||||
// bucket interface
|
// bucket interface
|
||||||
|
|
||||||
size_type bucket_count() const
|
size_type bucket_count() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.bucket_count_;
|
return table_.bucket_count_;
|
||||||
}
|
}
|
||||||
|
|
||||||
size_type max_bucket_count() const
|
size_type max_bucket_count() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.max_bucket_count();
|
return table_.max_bucket_count();
|
||||||
}
|
}
|
||||||
@ -979,13 +979,13 @@ namespace unordered
|
|||||||
|
|
||||||
// hash policy
|
// hash policy
|
||||||
|
|
||||||
float max_load_factor() const
|
float max_load_factor() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.mlf_;
|
return table_.mlf_;
|
||||||
}
|
}
|
||||||
|
|
||||||
float load_factor() const;
|
float load_factor() const BOOST_NOEXCEPT;
|
||||||
void max_load_factor(float);
|
void max_load_factor(float) BOOST_NOEXCEPT;
|
||||||
void rehash(size_type);
|
void rehash(size_type);
|
||||||
void reserve(size_type);
|
void reserve(size_type);
|
||||||
|
|
||||||
@ -1105,7 +1105,7 @@ namespace unordered
|
|||||||
// size and capacity
|
// size and capacity
|
||||||
|
|
||||||
template <class K, class T, class H, class P, class A>
|
template <class K, class T, class H, class P, class A>
|
||||||
std::size_t unordered_map<K,T,H,P,A>::max_size() const
|
std::size_t unordered_map<K,T,H,P,A>::max_size() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.max_size();
|
return table_.max_size();
|
||||||
}
|
}
|
||||||
@ -1274,13 +1274,13 @@ namespace unordered
|
|||||||
// hash policy
|
// hash policy
|
||||||
|
|
||||||
template <class K, class T, class H, class P, class A>
|
template <class K, class T, class H, class P, class A>
|
||||||
float unordered_map<K,T,H,P,A>::load_factor() const
|
float unordered_map<K,T,H,P,A>::load_factor() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.load_factor();
|
return table_.load_factor();
|
||||||
}
|
}
|
||||||
|
|
||||||
template <class K, class T, class H, class P, class A>
|
template <class K, class T, class H, class P, class A>
|
||||||
void unordered_map<K,T,H,P,A>::max_load_factor(float m)
|
void unordered_map<K,T,H,P,A>::max_load_factor(float m) BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
table_.max_load_factor(m);
|
table_.max_load_factor(m);
|
||||||
}
|
}
|
||||||
@ -1438,7 +1438,7 @@ namespace unordered
|
|||||||
// size and capacity
|
// size and capacity
|
||||||
|
|
||||||
template <class K, class T, class H, class P, class A>
|
template <class K, class T, class H, class P, class A>
|
||||||
std::size_t unordered_multimap<K,T,H,P,A>::max_size() const
|
std::size_t unordered_multimap<K,T,H,P,A>::max_size() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.max_size();
|
return table_.max_size();
|
||||||
}
|
}
|
||||||
@ -1586,13 +1586,13 @@ namespace unordered
|
|||||||
// hash policy
|
// hash policy
|
||||||
|
|
||||||
template <class K, class T, class H, class P, class A>
|
template <class K, class T, class H, class P, class A>
|
||||||
float unordered_multimap<K,T,H,P,A>::load_factor() const
|
float unordered_multimap<K,T,H,P,A>::load_factor() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.load_factor();
|
return table_.load_factor();
|
||||||
}
|
}
|
||||||
|
|
||||||
template <class K, class T, class H, class P, class A>
|
template <class K, class T, class H, class P, class A>
|
||||||
void unordered_multimap<K,T,H,P,A>::max_load_factor(float m)
|
void unordered_multimap<K,T,H,P,A>::max_load_factor(float m) BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
table_.max_load_factor(m);
|
table_.max_load_factor(m);
|
||||||
}
|
}
|
||||||
|
@ -176,53 +176,53 @@ namespace unordered
|
|||||||
unordered_set& operator=(std::initializer_list<value_type>);
|
unordered_set& operator=(std::initializer_list<value_type>);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
allocator_type get_allocator() const
|
allocator_type get_allocator() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.node_alloc();
|
return table_.node_alloc();
|
||||||
}
|
}
|
||||||
|
|
||||||
// size and capacity
|
// size and capacity
|
||||||
|
|
||||||
bool empty() const
|
bool empty() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.size_ == 0;
|
return table_.size_ == 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
size_type size() const
|
size_type size() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.size_;
|
return table_.size_;
|
||||||
}
|
}
|
||||||
|
|
||||||
size_type max_size() const;
|
size_type max_size() const BOOST_NOEXCEPT;
|
||||||
|
|
||||||
// iterators
|
// iterators
|
||||||
|
|
||||||
iterator begin()
|
iterator begin() BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.begin();
|
return table_.begin();
|
||||||
}
|
}
|
||||||
|
|
||||||
const_iterator begin() const
|
const_iterator begin() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.begin();
|
return table_.begin();
|
||||||
}
|
}
|
||||||
|
|
||||||
iterator end()
|
iterator end() BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return iterator();
|
return iterator();
|
||||||
}
|
}
|
||||||
|
|
||||||
const_iterator end() const
|
const_iterator end() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return const_iterator();
|
return const_iterator();
|
||||||
}
|
}
|
||||||
|
|
||||||
const_iterator cbegin() const
|
const_iterator cbegin() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.begin();
|
return table_.begin();
|
||||||
}
|
}
|
||||||
|
|
||||||
const_iterator cend() const
|
const_iterator cend() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return const_iterator();
|
return const_iterator();
|
||||||
}
|
}
|
||||||
@ -434,12 +434,12 @@ namespace unordered
|
|||||||
|
|
||||||
// bucket interface
|
// bucket interface
|
||||||
|
|
||||||
size_type bucket_count() const
|
size_type bucket_count() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.bucket_count_;
|
return table_.bucket_count_;
|
||||||
}
|
}
|
||||||
|
|
||||||
size_type max_bucket_count() const
|
size_type max_bucket_count() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.max_bucket_count();
|
return table_.max_bucket_count();
|
||||||
}
|
}
|
||||||
@ -486,13 +486,13 @@ namespace unordered
|
|||||||
|
|
||||||
// hash policy
|
// hash policy
|
||||||
|
|
||||||
float max_load_factor() const
|
float max_load_factor() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.mlf_;
|
return table_.mlf_;
|
||||||
}
|
}
|
||||||
|
|
||||||
float load_factor() const;
|
float load_factor() const BOOST_NOEXCEPT;
|
||||||
void max_load_factor(float);
|
void max_load_factor(float) BOOST_NOEXCEPT;
|
||||||
void rehash(size_type);
|
void rehash(size_type);
|
||||||
void reserve(size_type);
|
void reserve(size_type);
|
||||||
|
|
||||||
@ -644,53 +644,53 @@ namespace unordered
|
|||||||
unordered_multiset& operator=(std::initializer_list<value_type>);
|
unordered_multiset& operator=(std::initializer_list<value_type>);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
allocator_type get_allocator() const
|
allocator_type get_allocator() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.node_alloc();
|
return table_.node_alloc();
|
||||||
}
|
}
|
||||||
|
|
||||||
// size and capacity
|
// size and capacity
|
||||||
|
|
||||||
bool empty() const
|
bool empty() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.size_ == 0;
|
return table_.size_ == 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
size_type size() const
|
size_type size() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.size_;
|
return table_.size_;
|
||||||
}
|
}
|
||||||
|
|
||||||
size_type max_size() const;
|
size_type max_size() const BOOST_NOEXCEPT;
|
||||||
|
|
||||||
// iterators
|
// iterators
|
||||||
|
|
||||||
iterator begin()
|
iterator begin() BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return iterator(table_.begin());
|
return iterator(table_.begin());
|
||||||
}
|
}
|
||||||
|
|
||||||
const_iterator begin() const
|
const_iterator begin() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return const_iterator(table_.begin());
|
return const_iterator(table_.begin());
|
||||||
}
|
}
|
||||||
|
|
||||||
iterator end()
|
iterator end() BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return iterator();
|
return iterator();
|
||||||
}
|
}
|
||||||
|
|
||||||
const_iterator end() const
|
const_iterator end() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return const_iterator();
|
return const_iterator();
|
||||||
}
|
}
|
||||||
|
|
||||||
const_iterator cbegin() const
|
const_iterator cbegin() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return const_iterator(table_.begin());
|
return const_iterator(table_.begin());
|
||||||
}
|
}
|
||||||
|
|
||||||
const_iterator cend() const
|
const_iterator cend() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return const_iterator();
|
return const_iterator();
|
||||||
}
|
}
|
||||||
@ -902,12 +902,12 @@ namespace unordered
|
|||||||
|
|
||||||
// bucket interface
|
// bucket interface
|
||||||
|
|
||||||
size_type bucket_count() const
|
size_type bucket_count() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.bucket_count_;
|
return table_.bucket_count_;
|
||||||
}
|
}
|
||||||
|
|
||||||
size_type max_bucket_count() const
|
size_type max_bucket_count() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.max_bucket_count();
|
return table_.max_bucket_count();
|
||||||
}
|
}
|
||||||
@ -954,13 +954,13 @@ namespace unordered
|
|||||||
|
|
||||||
// hash policy
|
// hash policy
|
||||||
|
|
||||||
float max_load_factor() const
|
float max_load_factor() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.mlf_;
|
return table_.mlf_;
|
||||||
}
|
}
|
||||||
|
|
||||||
float load_factor() const;
|
float load_factor() const BOOST_NOEXCEPT;
|
||||||
void max_load_factor(float);
|
void max_load_factor(float) BOOST_NOEXCEPT;
|
||||||
void rehash(size_type);
|
void rehash(size_type);
|
||||||
void reserve(size_type);
|
void reserve(size_type);
|
||||||
|
|
||||||
@ -1080,7 +1080,7 @@ namespace unordered
|
|||||||
// size and capacity
|
// size and capacity
|
||||||
|
|
||||||
template <class T, class H, class P, class A>
|
template <class T, class H, class P, class A>
|
||||||
std::size_t unordered_set<T,H,P,A>::max_size() const
|
std::size_t unordered_set<T,H,P,A>::max_size() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.max_size();
|
return table_.max_size();
|
||||||
}
|
}
|
||||||
@ -1200,13 +1200,13 @@ namespace unordered
|
|||||||
// hash policy
|
// hash policy
|
||||||
|
|
||||||
template <class T, class H, class P, class A>
|
template <class T, class H, class P, class A>
|
||||||
float unordered_set<T,H,P,A>::load_factor() const
|
float unordered_set<T,H,P,A>::load_factor() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.load_factor();
|
return table_.load_factor();
|
||||||
}
|
}
|
||||||
|
|
||||||
template <class T, class H, class P, class A>
|
template <class T, class H, class P, class A>
|
||||||
void unordered_set<T,H,P,A>::max_load_factor(float m)
|
void unordered_set<T,H,P,A>::max_load_factor(float m) BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
table_.max_load_factor(m);
|
table_.max_load_factor(m);
|
||||||
}
|
}
|
||||||
@ -1364,7 +1364,7 @@ namespace unordered
|
|||||||
// size and capacity
|
// size and capacity
|
||||||
|
|
||||||
template <class T, class H, class P, class A>
|
template <class T, class H, class P, class A>
|
||||||
std::size_t unordered_multiset<T,H,P,A>::max_size() const
|
std::size_t unordered_multiset<T,H,P,A>::max_size() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.max_size();
|
return table_.max_size();
|
||||||
}
|
}
|
||||||
@ -1484,13 +1484,13 @@ namespace unordered
|
|||||||
// hash policy
|
// hash policy
|
||||||
|
|
||||||
template <class T, class H, class P, class A>
|
template <class T, class H, class P, class A>
|
||||||
float unordered_multiset<T,H,P,A>::load_factor() const
|
float unordered_multiset<T,H,P,A>::load_factor() const BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
return table_.load_factor();
|
return table_.load_factor();
|
||||||
}
|
}
|
||||||
|
|
||||||
template <class T, class H, class P, class A>
|
template <class T, class H, class P, class A>
|
||||||
void unordered_multiset<T,H,P,A>::max_load_factor(float m)
|
void unordered_multiset<T,H,P,A>::max_load_factor(float m) BOOST_NOEXCEPT
|
||||||
{
|
{
|
||||||
table_.max_load_factor(m);
|
table_.max_load_factor(m);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user