Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-08-17 08:39:21

0001 #ifndef BOOST_COMPAT_NONTYPE_HPP_INCLUDED
0002 #define BOOST_COMPAT_NONTYPE_HPP_INCLUDED
0003 
0004 // Copyright 2024 Christian Mazakas
0005 // Copyright 2025 Peter Dimov
0006 // Distributed under the Boost Software License, Version 1.0.
0007 // https://www.boost.org/LICENSE_1_0.txt
0008 
0009 #include <boost/config.hpp>
0010 
0011 namespace boost {
0012 namespace compat {
0013 
0014 namespace detail {
0015 
0016 template<class V, V v> struct nttp_holder
0017 {
0018 };
0019 
0020 } // namespace detail
0021 
0022 #if defined(__cpp_nontype_template_parameter_auto) && __cpp_nontype_template_parameter_auto >= 201606L
0023 
0024 template<auto V> struct nontype_t: public detail::nttp_holder<decltype(V), V>
0025 {
0026     explicit nontype_t() = default;
0027 };
0028 
0029 template<auto V>
0030 BOOST_INLINE_CONSTEXPR nontype_t<V> nontype {};
0031 
0032 #endif
0033 
0034 } // namespace compat
0035 } // namespace boost
0036 
0037 #endif // BOOST_COMPAT_NONTYPE_HPP_INCLUDED