// // Copyright 2019 Mateusz Loskot // // Distributed under the Boost Software License, Version 1.0 // See accompanying file LICENSE_1_0.txt or copy at // http://www.boost.org/LICENSE_1_0.txt // // FIXME: Avoid Clang's flooding of non-disableable warnings like: // "T does not declare any constructor to initialize its non-modifiable members" // when compiling with concepts check enabled. // See https://bugs.llvm.org/show_bug.cgi?id=41759 #if !defined(BOOST_GIL_USE_CONCEPT_CHECK) && !defined(__clang__) #error Compile with BOOST_GIL_USE_CONCEPT_CHECK defined #endif #include #include #include #include #include #include namespace gil = boost::gil; using boost::function_requires; template void test_immutable() { function_requires>(); function_requires>(); function_requires>(); } template void test_mutable() { function_requires>(); function_requires>(); function_requires>(); } template struct archetype_pixel_dereference { using point_t = gil::point_t; using const_t = archetype_pixel_dereference; using value_type = Pixel; using reference = value_type; using const_reference = value_type; using argument_type = gil::point_t; using result_type = reference; static constexpr bool is_mutable = false; result_type operator()(argument_type const&) const { return result_type{}; } }; template using virtual_locator = gil::virtual_2d_locator, false>; int main() { test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_immutable(); test_immutable(); test_immutable(); test_immutable(); test_immutable(); test_immutable(); test_immutable(); test_immutable(); test_mutable>(); test_immutable>(); test_mutable>(); test_immutable>(); test_mutable(); test_mutable(); test_mutable>(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_immutable(); test_immutable(); test_immutable>(); test_immutable(); test_immutable(); test_immutable(); test_immutable(); test_immutable(); test_immutable(); test_mutable(); test_mutable(); test_mutable>(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable>(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable>(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_immutable(); test_immutable(); test_immutable(); test_immutable(); test_immutable(); test_immutable(); test_immutable(); test_immutable(); test_mutable>(); test_immutable>(); test_mutable>(); test_immutable>(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable>(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable>(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_mutable(); test_immutable(); test_immutable(); test_immutable(); test_immutable(); test_immutable>(); }