mirror of
https://github.com/boostorg/static_assert.git
synced 2025-07-14 13:16:34 +02:00
Compare commits
3 Commits
boost-1.27
...
boost-1.28
Author | SHA1 | Date | |
---|---|---|---|
177bdd98ad | |||
b54c2d3fcb | |||
22bb032a79 |
@ -12,12 +12,12 @@
|
||||
#include <boost/static_assert.hpp>
|
||||
#include <boost/type_traits.hpp>
|
||||
|
||||
template <class RandonAccessIterator >
|
||||
RandonAccessIterator foo(RandonAccessIterator from, RandonAccessIterator)
|
||||
template <class RandomAccessIterator >
|
||||
RandomAccessIterator foo(RandomAccessIterator from, RandomAccessIterator)
|
||||
{
|
||||
// this template can only be used with
|
||||
// random access iterators...
|
||||
typedef typename std::iterator_traits< RandonAccessIterator >::iterator_category cat;
|
||||
typedef typename std::iterator_traits< RandomAccessIterator >::iterator_category cat;
|
||||
BOOST_STATIC_ASSERT((boost::is_convertible<cat*, std::random_access_iterator_tag*>::value));
|
||||
//
|
||||
// detail goes here...
|
||||
|
Reference in New Issue
Block a user