#include <cstddef>
#include <cassert>
#include <utility>
Go to the source code of this file.
Namespaces | |
nonstd | |
nonstd::detail | |
nonstd::optional_lite | |
nonstd::optional_lite::std11 | |
nonstd::optional_lite::detail | |
Typedefs | |
typedef nulltype | nonstd::optional_lite::detail::alignment_types |
Functions | |
template<class T > | |
in_place_t | nonstd::in_place (detail::in_place_type_tag< T >=detail::in_place_type_tag< T >()) |
template<std::size_t K> | |
in_place_t | nonstd::in_place (detail::in_place_index_tag< K >=detail::in_place_index_tag< K >()) |
template<class T > | |
in_place_t | nonstd::in_place_type (detail::in_place_type_tag< T >=detail::in_place_type_tag< T >()) |
template<std::size_t K> | |
in_place_t | nonstd::in_place_index (detail::in_place_index_tag< K >=detail::in_place_index_tag< K >()) |
template<typename T > | |
T & | nonstd::optional_lite::std11::move (T &t) |
typedef | nonstd::optional_lite::detail::optional_ALIGN_TYPE (char) |
typedef | nonstd::optional_lite::detail::optional_ALIGN_TYPE (short) |
typedef | nonstd::optional_lite::detail::optional_ALIGN_TYPE (int) |
typedef | nonstd::optional_lite::detail::optional_ALIGN_TYPE (long) |
typedef | nonstd::optional_lite::detail::optional_ALIGN_TYPE (float) |
typedef | nonstd::optional_lite::detail::optional_ALIGN_TYPE (double) |
typedef | nonstd::optional_lite::detail::optional_ALIGN_TYPE (long double) |
typedef | nonstd::optional_lite::detail::optional_ALIGN_TYPE (char *) |
typedef | nonstd::optional_lite::detail::optional_ALIGN_TYPE (short *) |
typedef | nonstd::optional_lite::detail::optional_ALIGN_TYPE (int *) |
typedef | nonstd::optional_lite::detail::optional_ALIGN_TYPE (long *) |
typedef | nonstd::optional_lite::detail::optional_ALIGN_TYPE (float *) |
typedef | nonstd::optional_lite::detail::optional_ALIGN_TYPE (double *) |
typedef | nonstd::optional_lite::detail::optional_ALIGN_TYPE (long double *) |
typedef | nonstd::optional_lite::detail::optional_ALIGN_TYPE (Unknown(*)(Unknown)) |
typedef | nonstd::optional_lite::detail::optional_ALIGN_TYPE (Unknown *Unknown::*) |
typedef | nonstd::optional_lite::detail::optional_ALIGN_TYPE (Unknown(Unknown::*)(Unknown)) |
template<typename T , typename U > | |
optional_constexpr bool | nonstd::optional_lite::operator== (optional< T > const &x, optional< U > const &y) |
template<typename T , typename U > | |
optional_constexpr bool | nonstd::optional_lite::operator!= (optional< T > const &x, optional< U > const &y) |
template<typename T , typename U > | |
optional_constexpr bool | nonstd::optional_lite::operator< (optional< T > const &x, optional< U > const &y) |
template<typename T , typename U > | |
optional_constexpr bool | nonstd::optional_lite::operator> (optional< T > const &x, optional< U > const &y) |
template<typename T , typename U > | |
optional_constexpr bool | nonstd::optional_lite::operator<= (optional< T > const &x, optional< U > const &y) |
template<typename T , typename U > | |
optional_constexpr bool | nonstd::optional_lite::operator>= (optional< T > const &x, optional< U > const &y) |
template<typename T > | |
optional_constexpr bool | nonstd::optional_lite::operator== (optional< T > const &x, nullopt_t) optional_noexcept |
template<typename T > | |
optional_constexpr bool | nonstd::optional_lite::operator== (nullopt_t, optional< T > const &x) optional_noexcept |
template<typename T > | |
optional_constexpr bool | nonstd::optional_lite::operator!= (optional< T > const &x, nullopt_t) optional_noexcept |
template<typename T > | |
optional_constexpr bool | nonstd::optional_lite::operator!= (nullopt_t, optional< T > const &x) optional_noexcept |
template<typename T > | |
optional_constexpr bool | nonstd::optional_lite::operator< (optional< T > const &, nullopt_t) optional_noexcept |
template<typename T > | |
optional_constexpr bool | nonstd::optional_lite::operator< (nullopt_t, optional< T > const &x) optional_noexcept |
template<typename T > | |
optional_constexpr bool | nonstd::optional_lite::operator<= (optional< T > const &x, nullopt_t) optional_noexcept |
template<typename T > | |
optional_constexpr bool | nonstd::optional_lite::operator<= (nullopt_t, optional< T > const &) optional_noexcept |
template<typename T > | |
optional_constexpr bool | nonstd::optional_lite::operator> (optional< T > const &x, nullopt_t) optional_noexcept |
template<typename T > | |
optional_constexpr bool | nonstd::optional_lite::operator> (nullopt_t, optional< T > const &) optional_noexcept |
template<typename T > | |
optional_constexpr bool | nonstd::optional_lite::operator>= (optional< T > const &, nullopt_t) optional_noexcept |
template<typename T > | |
optional_constexpr bool | nonstd::optional_lite::operator>= (nullopt_t, optional< T > const &x) optional_noexcept |
template<typename T , typename U > | |
optional_constexpr bool | nonstd::optional_lite::operator== (optional< T > const &x, U const &v) |
template<typename T , typename U > | |
optional_constexpr bool | nonstd::optional_lite::operator== (U const &v, optional< T > const &x) |
template<typename T , typename U > | |
optional_constexpr bool | nonstd::optional_lite::operator!= (optional< T > const &x, U const &v) |
template<typename T , typename U > | |
optional_constexpr bool | nonstd::optional_lite::operator!= (U const &v, optional< T > const &x) |
template<typename T , typename U > | |
optional_constexpr bool | nonstd::optional_lite::operator< (optional< T > const &x, U const &v) |
template<typename T , typename U > | |
optional_constexpr bool | nonstd::optional_lite::operator< (U const &v, optional< T > const &x) |
template<typename T , typename U > | |
optional_constexpr bool | nonstd::optional_lite::operator<= (optional< T > const &x, U const &v) |
template<typename T , typename U > | |
optional_constexpr bool | nonstd::optional_lite::operator<= (U const &v, optional< T > const &x) |
template<typename T , typename U > | |
optional_constexpr bool | nonstd::optional_lite::operator> (optional< T > const &x, U const &v) |
template<typename T , typename U > | |
optional_constexpr bool | nonstd::optional_lite::operator> (U const &v, optional< T > const &x) |
template<typename T , typename U > | |
optional_constexpr bool | nonstd::optional_lite::operator>= (optional< T > const &x, U const &v) |
template<typename T , typename U > | |
optional_constexpr bool | nonstd::optional_lite::operator>= (U const &v, optional< T > const &x) |
template<typename T > | |
void | nonstd::optional_lite::swap (optional< T > &x, optional< T > &y) |
template<typename T > | |
optional< T > | nonstd::optional_lite::make_optional (T const &value) |
Variables | |
const nullopt_t | nonstd::optional_lite::nullopt ((nullopt_t::init())) |
#define NONSTD_OPTIONAL_LITE_HPP |
Definition at line 13 of file optional.hpp.
#define optional_lite_MAJOR 3 |
Definition at line 15 of file optional.hpp.
#define optional_lite_MINOR 1 |
Definition at line 16 of file optional.hpp.
#define optional_lite_PATCH 1 |
Definition at line 17 of file optional.hpp.
#define optional_lite_VERSION optional_STRINGIFY(optional_lite_MAJOR) "." optional_STRINGIFY(optional_lite_MINOR) "." optional_STRINGIFY(optional_lite_PATCH) |
Definition at line 19 of file optional.hpp.
#define optional_STRINGIFY | ( | x | ) | optional_STRINGIFY_( x ) |
Definition at line 21 of file optional.hpp.
#define optional_STRINGIFY_ | ( | x | ) | #x |
Definition at line 22 of file optional.hpp.
#define optional_OPTIONAL_DEFAULT 0 |
Definition at line 26 of file optional.hpp.
#define optional_OPTIONAL_NONSTD 1 |
Definition at line 27 of file optional.hpp.
#define optional_OPTIONAL_STD 2 |
Definition at line 28 of file optional.hpp.
#define optional_CONFIG_SELECT_OPTIONAL ( optional_HAVE_STD_OPTIONAL ? optional_OPTIONAL_STD : optional_OPTIONAL_NONSTD ) |
Definition at line 31 of file optional.hpp.
#define optional_CONFIG_NO_EXCEPTIONS 1 |
Definition at line 40 of file optional.hpp.
#define optional_CPLUSPLUS __cplusplus |
Definition at line 51 of file optional.hpp.
#define optional_CPP98_OR_GREATER ( optional_CPLUSPLUS >= 199711L ) |
Definition at line 55 of file optional.hpp.
#define optional_CPP11_OR_GREATER ( optional_CPLUSPLUS >= 201103L ) |
Definition at line 56 of file optional.hpp.
#define optional_CPP11_OR_GREATER_ ( optional_CPLUSPLUS >= 201103L ) |
Definition at line 57 of file optional.hpp.
#define optional_CPP14_OR_GREATER ( optional_CPLUSPLUS >= 201402L ) |
Definition at line 58 of file optional.hpp.
#define optional_CPP17_OR_GREATER ( optional_CPLUSPLUS >= 201703L ) |
Definition at line 59 of file optional.hpp.
#define optional_CPP20_OR_GREATER ( optional_CPLUSPLUS >= 202000L ) |
Definition at line 60 of file optional.hpp.
#define optional_CPLUSPLUS_V ( optional_CPLUSPLUS / 100 - (optional_CPLUSPLUS > 200000 ? 2000 : 1994) ) |
Definition at line 64 of file optional.hpp.
#define optional_HAVE_STD_OPTIONAL 0 |
Definition at line 75 of file optional.hpp.
#define optional_USES_STD_OPTIONAL ( (optional_CONFIG_SELECT_OPTIONAL == optional_OPTIONAL_STD) || ((optional_CONFIG_SELECT_OPTIONAL == optional_OPTIONAL_DEFAULT) && optional_HAVE_STD_OPTIONAL) ) |
Definition at line 78 of file optional.hpp.
#define nonstd_lite_HAVE_IN_PLACE_TYPES 1 |
Definition at line 85 of file optional.hpp.
#define nonstd_lite_in_place_t | ( | T | ) | nonstd::in_place_t(&)( nonstd::detail::in_place_type_tag<T> ) |
Definition at line 155 of file optional.hpp.
#define nonstd_lite_in_place_type_t | ( | T | ) | nonstd::in_place_t(&)( nonstd::detail::in_place_type_tag<T> ) |
Definition at line 156 of file optional.hpp.
#define nonstd_lite_in_place_index_t | ( | K | ) | nonstd::in_place_t(&)( nonstd::detail::in_place_index_tag<K> ) |
Definition at line 157 of file optional.hpp.
#define nonstd_lite_in_place | ( | T | ) | nonstd::in_place_type<T> |
Definition at line 159 of file optional.hpp.
#define nonstd_lite_in_place_type | ( | T | ) | nonstd::in_place_type<T> |
Definition at line 160 of file optional.hpp.
#define nonstd_lite_in_place_index | ( | K | ) | nonstd::in_place_index<K> |
Definition at line 161 of file optional.hpp.
#define optional_CONFIG_MAX_ALIGN_HACK 0 |
Definition at line 203 of file optional.hpp.
#define optional_CONFIG_ALIGN_AS_FALLBACK double |
Definition at line 211 of file optional.hpp.
#define optional_BETWEEN | ( | v, | |
lo, | |||
hi | |||
) | ( (lo) <= (v) && (v) < (hi) ) |
Definition at line 227 of file optional.hpp.
#define optional_COMPILER_MSVC_VER 0 |
Definition at line 246 of file optional.hpp.
#define optional_COMPILER_MSVC_VERSION 0 |
Definition at line 247 of file optional.hpp.
#define optional_COMPILER_VERSION | ( | major, | |
minor, | |||
patch | |||
) | ( 10 * (10 * (major) + (minor) ) + (patch) ) |
Definition at line 250 of file optional.hpp.
#define optional_COMPILER_GNUC_VERSION 0 |
Definition at line 255 of file optional.hpp.
#define optional_COMPILER_CLANG_VERSION 0 |
Definition at line 261 of file optional.hpp.
#define optional_HAVE | ( | FEATURE | ) | ( optional_HAVE_##FEATURE ) |
Definition at line 274 of file optional.hpp.
#define optional_HAS_CPP0X 0 |
Definition at line 279 of file optional.hpp.
#define optional_CPP11_90 (optional_CPP11_OR_GREATER_ || optional_COMPILER_MSVC_VER >= 1500) |
Definition at line 289 of file optional.hpp.
#define optional_CPP11_100 (optional_CPP11_OR_GREATER_ || optional_COMPILER_MSVC_VER >= 1600) |
Definition at line 290 of file optional.hpp.
#define optional_CPP11_110 (optional_CPP11_OR_GREATER_ || optional_COMPILER_MSVC_VER >= 1700) |
Definition at line 291 of file optional.hpp.
#define optional_CPP11_120 (optional_CPP11_OR_GREATER_ || optional_COMPILER_MSVC_VER >= 1800) |
Definition at line 292 of file optional.hpp.
#define optional_CPP11_140 (optional_CPP11_OR_GREATER_ || optional_COMPILER_MSVC_VER >= 1900) |
Definition at line 293 of file optional.hpp.
#define optional_CPP11_141 (optional_CPP11_OR_GREATER_ || optional_COMPILER_MSVC_VER >= 1910) |
Definition at line 294 of file optional.hpp.
#define optional_CPP14_000 (optional_CPP14_OR_GREATER) |
Definition at line 296 of file optional.hpp.
#define optional_CPP17_000 (optional_CPP17_OR_GREATER) |
Definition at line 297 of file optional.hpp.
#define optional_HAVE_CONSTEXPR_11 optional_CPP11_140 |
Definition at line 301 of file optional.hpp.
#define optional_HAVE_IS_DEFAULT optional_CPP11_140 |
Definition at line 302 of file optional.hpp.
#define optional_HAVE_NOEXCEPT optional_CPP11_140 |
Definition at line 303 of file optional.hpp.
#define optional_HAVE_NULLPTR optional_CPP11_100 |
Definition at line 304 of file optional.hpp.
#define optional_HAVE_REF_QUALIFIER optional_CPP11_140 |
Definition at line 305 of file optional.hpp.
#define optional_HAVE_CONSTEXPR_14 optional_CPP14_000 |
Definition at line 309 of file optional.hpp.
#define optional_HAVE_NODISCARD optional_CPP17_000 |
Definition at line 313 of file optional.hpp.
#define optional_HAVE_CONDITIONAL optional_CPP11_120 |
Definition at line 317 of file optional.hpp.
#define optional_HAVE_REMOVE_CV optional_CPP11_120 |
Definition at line 318 of file optional.hpp.
#define optional_HAVE_TYPE_TRAITS optional_CPP11_90 |
Definition at line 319 of file optional.hpp.
#define optional_HAVE_TR1_TYPE_TRAITS (!! optional_COMPILER_GNUC_VERSION ) |
Definition at line 321 of file optional.hpp.
#define optional_HAVE_TR1_ADD_POINTER (!! optional_COMPILER_GNUC_VERSION ) |
Definition at line 322 of file optional.hpp.
#define optional_constexpr /*constexpr*/ |
Definition at line 329 of file optional.hpp.
#define optional_is_default {} |
Definition at line 335 of file optional.hpp.
#define optional_constexpr14 /*constexpr*/ |
Definition at line 341 of file optional.hpp.
#define optional_nodiscard /*[[nodiscard]]*/ |
Definition at line 347 of file optional.hpp.
#define optional_noexcept /*noexcept*/ |
Definition at line 353 of file optional.hpp.
#define optional_nullptr NULL |
Definition at line 359 of file optional.hpp.
#define optional_ref_qual /*&*/ |
Definition at line 367 of file optional.hpp.
#define optional_refref_qual /*&&*/ |
Definition at line 368 of file optional.hpp.
#define optional_ALIGN_AS | ( | to_align | ) | typename type_of_size< alignment_types, alignment_of< to_align >::value >::type |
Definition at line 593 of file optional.hpp.
#define optional_ALIGN_TYPE | ( | type | ) | typelist< type , typelist< struct_t< type > |
Definition at line 638 of file optional.hpp.