Boost C++ Libraries

...one of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

This is the documentation for a snapshot of the develop branch, built from commit d7c8a7cf0d.
PrevUpHomeNext

Introduction

Boost.FunctionTypes provides functionality to classify, decompose and synthesize function, function pointer, function reference and pointer to member types.

We collectively refer to these types as callable builtin types.

In particular, the library can be used to:

The library is designed to work well with other Boost libraries and uses well-accepted concepts introduced by Boost and TR1.

Templates that encapsulate boolean or numeric properties define a static member constant called value.

is_function_pointer< bool(*)(int) >::value // == true 

function_arity< bool(*)(int) >::value // == 1

Templates that encapsulate properties that are single types contain a type member called type.

function_type< mpl::vector<bool,int> >::type // is bool(int)

result_type< bool(&)(int) >::type // is bool

Templates that encapsulate properties that are type lists model an MPL-compatible type sequence.

parameter_types< bool(int) > // models an MPL sequence

PrevUpHomeNext