get rid of remaining zero-as-null-pointer-constant usages
parent
d7d3929226
commit
64843f7aa7
|
@ -73,7 +73,7 @@ int main() {
|
||||||
/* more complex pipe */
|
/* more complex pipe */
|
||||||
writeln("several piped algorithms");
|
writeln("several piped algorithms");
|
||||||
|
|
||||||
srand(static_cast<unsigned int>(time(0)));
|
srand(static_cast<unsigned int>(std::time(nullptr)));
|
||||||
std::array<int, 100> arr;
|
std::array<int, 100> arr;
|
||||||
generate(iter(arr), []() { return rand() % 128; });
|
generate(iter(arr), []() { return rand() % 128; });
|
||||||
|
|
||||||
|
|
|
@ -177,17 +177,16 @@ struct contiguous_range_tag: finite_random_access_range_tag {};
|
||||||
|
|
||||||
namespace detail {
|
namespace detail {
|
||||||
template<typename R>
|
template<typename R>
|
||||||
struct range_category_test {
|
inline auto range_category_test(int) -> std::integral_constant<
|
||||||
template<typename RR>
|
bool, !std::is_void_v<typename R::range_category>
|
||||||
static char test(typename RR::range_category *);
|
>;
|
||||||
template<typename>
|
|
||||||
static int test(...);
|
template<typename>
|
||||||
static constexpr bool value = (sizeof(test<R>(0)) == sizeof(char));
|
inline std::false_type range_category_test(...);
|
||||||
};
|
|
||||||
|
|
||||||
template<typename R>
|
template<typename R>
|
||||||
static inline constexpr bool const test_range_category =
|
static inline constexpr bool const test_range_category =
|
||||||
range_category_test<R>::value;
|
decltype(range_category_test<R>(0))::value;
|
||||||
|
|
||||||
template<typename R, bool, bool>
|
template<typename R, bool, bool>
|
||||||
struct range_traits_base {
|
struct range_traits_base {
|
||||||
|
|
Loading…
Reference in New Issue