One Hat Cyber Team
Your IP :
216.73.216.231
Server IP :
162.240.179.46
Server :
Linux vps-14493116.nutrivittasaude.com.br 5.14.0-687.17.1.el9_8.x86_64 #1 SMP PREEMPT_DYNAMIC Mon Jun 22 07:21:26 EDT 2026 x86_64
Server Software :
Apache
PHP Version :
8.2.31
Buat File
|
Buat Folder
Eksekusi
Dir :
~
/
usr
/
include
/
boost
/
pfr
/
detail
/
View File Name :
unsafe_declval.hpp
// Copyright (c) 2019-2020 Antony Polukhin. // // 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 BOOST_PFR_DETAIL_UNSAFE_DECLVAL_HPP #define BOOST_PFR_DETAIL_UNSAFE_DECLVAL_HPP #include <boost/pfr/detail/config.hpp> #include <type_traits> namespace boost { namespace pfr { namespace detail { // This function serves as a link-time assert. If linker requires it, then // `unsafe_declval()` is used at runtime. void report_if_you_see_link_error_with_this_function() noexcept; // For returning non default constructible types. Do NOT use at runtime! // // GCCs std::declval may not be used in potentionally evaluated contexts, // so we reinvent it. template <class T> constexpr T unsafe_declval() noexcept { report_if_you_see_link_error_with_this_function(); typename std::remove_reference<T>::type* ptr = 0; ptr += 42; // suppresses 'null pointer dereference' warnings return static_cast<T>(*ptr); } }}} // namespace boost::pfr::detail #endif // BOOST_PFR_DETAIL_UNSAFE_DECLVAL_HPP