LLVM  16.0.0git
Public Member Functions | List of all members
llvm::optional_detail::OptionalStorage< T, true > Class Template Reference

#include "llvm/ADT/Optional.h"

Collaboration diagram for llvm::optional_detail::OptionalStorage< T, true >:
Collaboration graph
[legend]

Public Member Functions

 ~OptionalStorage ()=default
 
constexpr OptionalStorage () noexcept
 
constexpr OptionalStorage (OptionalStorage const &other)=default
 
constexpr OptionalStorage (OptionalStorage &&other)=default
 
OptionalStorageoperator= (OptionalStorage const &other)=default
 
OptionalStorageoperator= (OptionalStorage &&other)=default
 
template<class... Args>
constexpr OptionalStorage (std::in_place_t, Args &&...args)
 
void reset () noexcept
 
constexpr bool has_value () const noexcept
 
constexpr bool hasValue () const noexcept
 
T & value () &noexcept
 
 LLVM_DEPRECATED ("Use value instead.", "value") T &getValue() &noexcept
 
constexpr const T & value () const &noexcept
 
constexpr const T & getValue () const &noexcept
 
T && value () &&noexcept
 
 LLVM_DEPRECATED ("Use value instead.", "value") T &&getValue() &&noexcept
 
template<class... Args>
void emplace (Args &&...args)
 
OptionalStorageoperator= (T const &y)
 
OptionalStorageoperator= (T &&y)
 

Detailed Description

template<typename T>
class llvm::optional_detail::OptionalStorage< T, true >

Definition at line 180 of file Optional.h.

Constructor & Destructor Documentation

◆ ~OptionalStorage()

template<typename T >
llvm::optional_detail::OptionalStorage< T, true >::~OptionalStorage ( )
default

◆ OptionalStorage() [1/4]

template<typename T >
constexpr llvm::optional_detail::OptionalStorage< T, true >::OptionalStorage ( )
inlineconstexprnoexcept

Definition at line 190 of file Optional.h.

◆ OptionalStorage() [2/4]

template<typename T >
constexpr llvm::optional_detail::OptionalStorage< T, true >::OptionalStorage ( OptionalStorage< T, true > const other)
constexprdefault

◆ OptionalStorage() [3/4]

template<typename T >
constexpr llvm::optional_detail::OptionalStorage< T, true >::OptionalStorage ( OptionalStorage< T, true > &&  other)
constexprdefault

◆ OptionalStorage() [4/4]

template<typename T >
template<class... Args>
constexpr llvm::optional_detail::OptionalStorage< T, true >::OptionalStorage ( std::in_place_t  ,
Args &&...  args 
)
inlineexplicitconstexpr

Definition at line 199 of file Optional.h.

Member Function Documentation

◆ emplace()

template<typename T >
template<class... Args>
void llvm::optional_detail::OptionalStorage< T, true >::emplace ( Args &&...  args)
inline

◆ getValue()

template<typename T >
constexpr const T& llvm::optional_detail::OptionalStorage< T, true >::getValue ( ) const &
inlineconstexprnoexcept

Definition at line 228 of file Optional.h.

References assert(), and llvm::optional_detail::OptionalStorage< T, bool >::val.

◆ has_value()

template<typename T >
constexpr bool llvm::optional_detail::OptionalStorage< T, true >::has_value ( ) const
inlineconstexprnoexcept

Definition at line 209 of file Optional.h.

◆ hasValue()

template<typename T >
constexpr bool llvm::optional_detail::OptionalStorage< T, true >::hasValue ( ) const
inlineconstexprnoexcept

Definition at line 211 of file Optional.h.

◆ LLVM_DEPRECATED() [1/2]

template<typename T >
llvm::optional_detail::OptionalStorage< T, true >::LLVM_DEPRECATED ( "Use value instead."  ,
"value"   
) &&
inlinenoexcept

◆ LLVM_DEPRECATED() [2/2]

template<typename T >
llvm::optional_detail::OptionalStorage< T, true >::LLVM_DEPRECATED ( "Use value instead."  ,
"value"   
) &
inlinenoexcept

Definition at line 219 of file Optional.h.

References assert(), and llvm::optional_detail::OptionalStorage< T, bool >::val.

◆ operator=() [1/4]

template<typename T >
OptionalStorage& llvm::optional_detail::OptionalStorage< T, true >::operator= ( OptionalStorage< T, true > &&  other)
default

◆ operator=() [2/4]

template<typename T >
OptionalStorage& llvm::optional_detail::OptionalStorage< T, true >::operator= ( OptionalStorage< T, true > const other)
default

◆ operator=() [3/4]

template<typename T >
OptionalStorage& llvm::optional_detail::OptionalStorage< T, true >::operator= ( T &&  y)
inline

◆ operator=() [4/4]

template<typename T >
OptionalStorage& llvm::optional_detail::OptionalStorage< T, true >::operator= ( T const y)
inline

◆ reset()

template<typename T >
void llvm::optional_detail::OptionalStorage< T, true >::reset ( )
inlinenoexcept

◆ value() [1/3]

template<typename T >
T&& llvm::optional_detail::OptionalStorage< T, true >::value ( ) &&
inlinenoexcept

Definition at line 232 of file Optional.h.

References assert(), move, T, and llvm::optional_detail::OptionalStorage< T, bool >::val.

◆ value() [2/3]

template<typename T >
T& llvm::optional_detail::OptionalStorage< T, true >::value ( ) &
inlinenoexcept

Definition at line 215 of file Optional.h.

References assert(), T, and llvm::optional_detail::OptionalStorage< T, bool >::val.

◆ value() [3/3]

template<typename T >
constexpr const T& llvm::optional_detail::OptionalStorage< T, true >::value ( ) const &
inlineconstexprnoexcept

Definition at line 223 of file Optional.h.

References assert(), T, and llvm::optional_detail::OptionalStorage< T, bool >::val.

Member Data Documentation

◆ empty

template<typename T >
char llvm::optional_detail::OptionalStorage< T, true >::empty

Definition at line 182 of file Optional.h.

◆ val

template<typename T >
T llvm::optional_detail::OptionalStorage< T, true >::val

Definition at line 183 of file Optional.h.


The documentation for this class was generated from the following file: