|
LLVM
4.0.0
|
A pointer union of four pointer types. More...
#include <PointerUnion.h>
Public Types | |
| typedef PointerUnion< PT1, PT2 > | InnerUnion1 |
| typedef PointerUnion< PT3, PT4 > | InnerUnion2 |
| typedef PointerUnion < InnerUnion1, InnerUnion2 > | ValTy |
Public Member Functions | |
| PointerUnion4 ()=default | |
| PointerUnion4 (PT1 V) | |
| PointerUnion4 (PT2 V) | |
| PointerUnion4 (PT3 V) | |
| PointerUnion4 (PT4 V) | |
| bool | isNull () const |
| Test if the pointer held in the union is null, regardless of which type it is. More... | |
| operator bool () const | |
| template<typename T > | |
| int | is () const |
| Test if the Union currently holds the type matching T. More... | |
| template<typename T > | |
| T | get () const |
| Returns the value of the specified pointer type. More... | |
| template<typename T > | |
| T | dyn_cast () const |
| Returns the current pointer if it is of the specified pointer type, otherwises returns null. More... | |
| const PointerUnion4 & | operator= (std::nullptr_t) |
| Assignment from nullptr which just clears the union. More... | |
| const PointerUnion4 & | operator= (const PT1 &RHS) |
| Assignment operators - Allow assigning into this union from either pointer type, setting the discriminator to remember what it came from. More... | |
| const PointerUnion4 & | operator= (const PT2 &RHS) |
| const PointerUnion4 & | operator= (const PT3 &RHS) |
| const PointerUnion4 & | operator= (const PT4 &RHS) |
| void * | getOpaqueValue () const |
Static Public Member Functions | |
| static PointerUnion4 | getFromOpaqueValue (void *VP) |
A pointer union of four pointer types.
See documentation for PointerUnion for usage.
Definition at line 351 of file PointerUnion.h.
| typedef PointerUnion<PT1, PT2> llvm::PointerUnion4< PT1, PT2, PT3, PT4 >::InnerUnion1 |
Definition at line 353 of file PointerUnion.h.
| typedef PointerUnion<PT3, PT4> llvm::PointerUnion4< PT1, PT2, PT3, PT4 >::InnerUnion2 |
Definition at line 354 of file PointerUnion.h.
| typedef PointerUnion<InnerUnion1, InnerUnion2> llvm::PointerUnion4< PT1, PT2, PT3, PT4 >::ValTy |
Definition at line 355 of file PointerUnion.h.
|
default |
|
inline |
Definition at line 363 of file PointerUnion.h.
|
inline |
Definition at line 364 of file PointerUnion.h.
|
inline |
Definition at line 365 of file PointerUnion.h.
|
inline |
Definition at line 366 of file PointerUnion.h.
|
inline |
Returns the current pointer if it is of the specified pointer type, otherwises returns null.
Definition at line 396 of file PointerUnion.h.
References T.
|
inline |
Returns the value of the specified pointer type.
If the specified pointer type is incorrect, assert.
Definition at line 385 of file PointerUnion.h.
References assert(), llvm::MCID::Return, and T.
|
inlinestatic |
Definition at line 428 of file PointerUnion.h.
References llvm::PointerUnion< InnerUnion1, InnerUnion2 >::getFromOpaqueValue().
Referenced by llvm::PointerLikeTypeTraits< PointerUnion4< PT1, PT2, PT3, PT4 > >::getFromVoidPointer().
|
inline |
Definition at line 427 of file PointerUnion.h.
References llvm::PointerUnion< PT1, PT2 >::getOpaqueValue().
Referenced by llvm::PointerLikeTypeTraits< PointerUnion4< PT1, PT2, PT3, PT4 > >::getAsVoidPointer().
|
inline |
Test if the Union currently holds the type matching T.
Definition at line 374 of file PointerUnion.h.
References llvm::MCID::Return, and T.
|
inline |
Test if the pointer held in the union is null, regardless of which type it is.
Definition at line 370 of file PointerUnion.h.
References llvm::PointerUnion< PT1, PT2 >::isNull().
Referenced by llvm::PointerUnion4< PT1, PT2, PT3, PT4 >::operator bool().
|
inlineexplicit |
Definition at line 371 of file PointerUnion.h.
References llvm::PointerUnion4< PT1, PT2, PT3, PT4 >::isNull().
|
inline |
Assignment from nullptr which just clears the union.
Definition at line 403 of file PointerUnion.h.
|
inline |
Assignment operators - Allow assigning into this union from either pointer type, setting the discriminator to remember what it came from.
Definition at line 410 of file PointerUnion.h.
|
inline |
Definition at line 414 of file PointerUnion.h.
|
inline |
Definition at line 418 of file PointerUnion.h.
|
inline |
Definition at line 422 of file PointerUnion.h.
1.8.6