fail

Synopsis

template <class MonadTag, class S>
struct fail
{
  // unspecified
};

Description

fail is a metafunction for the fail operation of the monad typeclass.

#include <mpllibs/metamonad/fail.hpp>

Expression semantics

For any monad_tag tag and s class:

fail<monad_tag, s>

is equivalent to

apply<monad<monad_tag>::fail, s>

Example

struct one_error;

typedef fail<maybe_tag, one_error>::type this_is_nothing;

[up]