diff --git a/include/mapnik/params_impl.hpp b/include/mapnik/params_impl.hpp index 9d64f0b90..85a74a7fb 100644 --- a/include/mapnik/params_impl.hpp +++ b/include/mapnik/params_impl.hpp @@ -148,16 +148,17 @@ struct value_extractor_visitor : public boost::static_visitor<> template void operator () (T1 val) const { - // TODO try { var_ = boost::lexical_cast(val); } - catch (boost::bad_lexical_cast & ) {} - //std::string err_msg = (boost::format("No conversion from %s to %s") - // % typeid(T1).name() - // % typeid(T).name()).str(); - //throw std::runtime_error(err_msg); + catch (boost::bad_lexical_cast & ) + { + std::string err_msg = (boost::format("Failed converting from %s to %s") + % typeid(T1).name() + % typeid(T).name()).str(); + throw std::runtime_error(err_msg); + } }