LLVM 22.0.0git
llvm::Any Class Reference

#include "llvm/ADT/Any.h"

Public Member Functions

 Any ()=default
 Any (const Any &Other)
template<typename T, std::enable_if_t< std::conjunction< std::negation< std::is_same< std::decay_t< T >, Any > >, std::negation< std::is_convertible< Any, std::decay_t< T > > >, std::is_copy_constructible< std::decay_t< T > > >::value, int > = 0>
 Any (T &&Value)
 Any (Any &&Other)
Anyswap (Any &Other)
Anyoperator= (Any Other)
bool has_value () const
void reset ()

Friends

template<class T>
T any_cast (const Any &Value)
template<class T>
T any_cast (Any &Value)
template<class T>
T any_cast (Any &&Value)
template<class T>
const Tany_cast (const Any *Value)
template<class T>
Tany_cast (Any *Value)

Detailed Description

Definition at line 28 of file Any.h.

Constructor & Destructor Documentation

◆ Any() [1/4]

llvm::Any::Any ( )
default

◆ Any() [2/4]

llvm::Any::Any ( const Any & Other)
inline

Definition at line 65 of file Any.h.

References Any(), and llvm::Other.

◆ Any() [3/4]

template<typename T, std::enable_if_t< std::conjunction< std::negation< std::is_same< std::decay_t< T >, Any > >, std::negation< std::is_convertible< Any, std::decay_t< T > > >, std::is_copy_constructible< std::decay_t< T > > >::value, int > = 0>
llvm::Any::Any ( T && Value)
inline

Definition at line 88 of file Any.h.

References T.

◆ Any() [4/4]

llvm::Any::Any ( Any && Other)
inline

Definition at line 93 of file Any.h.

References Any(), llvm::move(), and llvm::Other.

Member Function Documentation

◆ has_value()

bool llvm::Any::has_value ( ) const
inline

Definition at line 105 of file Any.h.

◆ operator=()

Any & llvm::Any::operator= ( Any Other)
inline

Definition at line 100 of file Any.h.

References Any(), and llvm::Other.

◆ reset()

void llvm::Any::reset ( )
inline

Definition at line 107 of file Any.h.

◆ swap()

Any & llvm::Any::swap ( Any & Other)
inline

Definition at line 95 of file Any.h.

References Any(), llvm::Other, and std::swap().

◆ any_cast [1/5]

template<class T>
T any_cast ( Any && Value)
friend

Definition at line 147 of file Any.h.

References Any(), any_cast, assert(), and T.

◆ any_cast [2/5]

template<class T>
T any_cast ( Any & Value)
friend

Definition at line 142 of file Any.h.

References Any(), any_cast, assert(), and T.

◆ any_cast [3/5]

template<class T>
T * any_cast ( Any * Value)
friend

Definition at line 159 of file Any.h.

References Any(), and T.

◆ any_cast [4/5]

template<class T>
T any_cast ( const Any & Value)
friend

Definition at line 137 of file Any.h.

References Any(), any_cast, assert(), and T.

Referenced by any_cast, any_cast, and any_cast.

◆ any_cast [5/5]

template<class T>
const T * any_cast ( const Any * Value)
friend

Definition at line 152 of file Any.h.

References Any(), and T.


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