Template Class Bool

Class Documentation

template<bool x>
class Bool

Integral constant wrapper for boolean values.

Provides an integral constant wrapper for boolean values (refer to C++ template metaprogramming by D.Abrahams p. 61 for details).

Public Types

typedef Bool<x> type

This wrapper’s nullary metafunction (simply returns itself).

typedef bool value_type

The type this wrapper’s value.

Public Functions

inline operator bool() const

Convenience conversion.

inline virtual ~Bool()

Public Static Attributes

static bool const value = x

The value for this integral constant wrapper.