Nullary Functions

Overview

Nullary functions are defined as an object (c++ class/struct) that is sometimes otherwise known as callable without any argument passing.

CompilingLinking

Include the following at the top of any translation unit for which you are running compile time checks on your blueprint classes.

Since it only uses macros and templatised objects, no linking is required for just this feature.

Concept Definition

Creating a class can be done in any namespace, it just has to satisfy the conditions outlined below:

Usage

Use with the compile time concept check whenever you wish to check for a nullary function object input. For example, the Thread class (ecl_threads) utilises this in a similar way to that outlined below:

    template<typename F>
    Thread(F function) {
        compile_time_concept_check(NullaryFunctionConcept<F>);
    }


ecl_concepts
Author(s): Daniel Stonier (d.stonier@gmail.com)
autogenerated on Thu Jan 2 2014 11:12:03