Itasca C++ Interface
|
Class used to select between two types based on a given condition. More...
#include <type_selector.h>
Static Public Attributes | |
static const bool | result |
Class used to select between two types based on a given condition.
condition | Either true or false; determines which specification to use. |
if_true | Type to be stored if true. |
if_false | Type to be stored if false. |
This class uses template metaprogramming to act as an "if" statement to determine whether to use one type or another. If compile-time values such as sizeof()
, or simply constants, are solely involved in condition
, this can be evaluated at compile time.