Move all<int> to .cpp file to remove <limits> from common path

This commit is contained in:
Martin Hořeňovský committed 2018-08-24 13:34:03 +02:00
1 parent fdcd46420e
commit 92e25049cf
2 files changed
+8 -6

No files matched your search

+3 -6
View File
@@ -13,7 +13,6 @@
#include <memory>
#include <vector>
#include <cassert>
#include <limits>
#include <utility>
@@ -123,16 +122,14 @@ namespace Generators {
template<typename T>
auto all() -> Generator<T> { return RequiresASpecialisationFor<T>(); }
template<>
auto all<int>() -> Generator<int>;
template<typename T>
auto range( T const& first, T const& last ) -> Generator<T> {
return Generator<T>( (last-first), pf::make_unique<RangeGenerator<T>>( first, last ) );
}
template<>
inline auto all<int>() -> Generator<int> {
return range( std::numeric_limits<int>::min(), std::numeric_limits<int>::max()-1 );
}
template<typename T>
auto random( T const& first, T const& last ) -> Generator<T> {