19#ifndef PYSTON_FUNCTION_H
20#define PYSTON_FUNCTION_H
37template <
typename R,
typename... Args>
79template <
typename Signature>
90template <
typename R,
typename... Args>
101 : m_repr(repr), m_functor(functor) {}
121#define PYSTON_GRAPH_FUNCTION_IMPL
123#undef PYSTON_GRAPH_FUNCTION_IMPL
std::shared_ptr< Node< R > > operator()(const std::shared_ptr< Node< Args > > &... nodes) const
std::function< R(const Context &, Args...)> m_functor
FunctionFactory(const std::string &repr, std::function< R(const Context &, Args...)> functor)
Function(const std::string &repr_, std::function< R(const Context &, Args...)> functor, const std::shared_ptr< Node< Args > >... args)
R eval(const Context &context, const Arguments &args) const final
void visit(Visitor &visitor) const final
std::string repr() const final