/*============================================================================= Copyright (c) 2011-2016 Bolero MURAKAMI https://github.com/bolero-MURAKAMI/Sprout 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) =============================================================================*/ #ifndef SPROUT_FUNCTIONAL_BIND_UDL_HPP #define SPROUT_FUNCTIONAL_BIND_UDL_HPP #include #include #if SPROUT_USE_USER_DEFINED_LITERALS #include #include namespace sprout { // // placeholders_result // variadic_placeholders_result // template struct placeholders_result : public sprout::identity< sprout::placeholder::value> > {}; template struct variadic_placeholders_result : public sprout::identity< sprout::placeholder::value - sprout::detail::digits_to_int::value> > {}; namespace udl { namespace placeholders { // // _ // _tail // template SPROUT_CONSTEXPR typename sprout::placeholders_result::type operator"" _() { typedef typename sprout::placeholders_result::type type; return type(); } template SPROUT_CONSTEXPR typename sprout::variadic_placeholders_result::type operator"" _tail() { typedef typename sprout::variadic_placeholders_result::type type; return type(); } } // namespace placeholders using sprout::udl::placeholders::operator"" _; using sprout::udl::placeholders::operator"" _tail; } // namespace udl } // namespace sprout #endif // #if SPROUT_USE_USER_DEFINED_LITERALS #endif // #ifndef SPROUT_FUNCTIONAL_BIND_UDL_HPP