Attached is an implementation of 'boost::tuples::apply' function template, providing one with a possibility of function application on a tuple of arguments:
#include "boost/tuple/tuple.hpp"
#include "boost/tuple/apply.hpp"
using namespace boost;
void f(int, char const*);
int main()
{
char const* text = "text";
tuples::apply(f, make_tuple(5, text)); // here
}
For those who knows Python, it's an equivalent of Python's built-in 'apply'
function.
IMO it's one of the fundamental tuple facilities, and I would love to
contribute it to the Boost.Tuple library, if it's welcome. Jaakko?
Aleksey
apply.hpp
Description: Binary data
_______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
