OpenLexocad  27.1
entt::y_combinator< Func > Struct Template Reference

Basic implementation of a y-combinator. More...

#include <entt.hpp>

Public Member Functions

 y_combinator (Func recursive)
 Constructs a y-combinator from a given function. More...
 
template<class... Args>
decltype(auto) operator() (Args &&... args) const
 Invokes a y-combinator and therefore its underlying function. More...
 
template<class... Args>
decltype(auto) operator() (Args &&... args)
 Invokes a y-combinator and therefore its underlying function. More...
 

Detailed Description

template<class Func>
struct entt::y_combinator< Func >

Basic implementation of a y-combinator.

Template Parameters
FuncType of a potentially recursive function.

Constructor & Destructor Documentation

◆ y_combinator()

template<class Func >
entt::y_combinator< Func >::y_combinator ( Func  recursive)
inline

Constructs a y-combinator from a given function.

Parameters
recursiveA potentially recursive function.

Member Function Documentation

◆ operator()() [1/2]

template<class Func >
template<class... Args>
decltype(auto) entt::y_combinator< Func >::operator() ( Args &&...  args) const
inline

Invokes a y-combinator and therefore its underlying function.

Template Parameters
ArgsTypes of arguments to use to invoke the underlying function.
Parameters
argsParameters to use to invoke the underlying function.
Returns
Return value of the underlying function, if any.

◆ operator()() [2/2]

template<class Func >
template<class... Args>
decltype(auto) entt::y_combinator< Func >::operator() ( Args &&...  args)
inline

Invokes a y-combinator and therefore its underlying function.

Template Parameters
ArgsTypes of arguments to use to invoke the underlying function.
Parameters
argsParameters to use to invoke the underlying function.
Returns
Return value of the underlying function, if any.

The documentation for this struct was generated from the following file: