/*! @file Defines `boost::hana::detail::variadic::at`. @copyright Louis Dionne 2013-2017 Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt) */ #ifndef BOOST_HANA_DETAIL_VARIADIC_AT_HPP #define BOOST_HANA_DETAIL_VARIADIC_AT_HPP #include #include #include namespace boost { namespace hana { namespace detail { namespace variadic { template > struct at_type; template struct at_type> { private: template static constexpr auto go(decltype(ignore, (void*)0)..., Nth nth, ...) { return nth; } public: template constexpr auto operator()(Xs ...xs) const { return *go(&xs...); } }; template BOOST_HANA_INLINE_VARIABLE constexpr at_type at{}; }} }} // end namespace boost::hana #endif // !BOOST_HANA_DETAIL_VARIADIC_AT_HPP