diff --git a/dispatchkit/bootstrap.hpp b/dispatchkit/bootstrap.hpp index d6dcbdd..5d75bce 100644 --- a/dispatchkit/bootstrap.hpp +++ b/dispatchkit/bootstrap.hpp @@ -391,6 +391,14 @@ namespace dispatchkit } } + template + Input parse_string(const std::string &i) + { + return boost::lexical_cast(i); + } + + + template void bootstrap_pod_type(Dispatch_Engine &s, const std::string &name) { @@ -401,6 +409,7 @@ namespace dispatchkit add_opers_arithmetic(s); add_opers_arithmetic_modify_pod(s); register_function(s, &to_string, "to_string"); + register_function(s, &parse_string, "to_" + name); } struct Bootstrap