diff --git a/include/mapnik/ptree_helpers.hpp b/include/mapnik/ptree_helpers.hpp index aa9c311f4..aaee81256 100644 --- a/include/mapnik/ptree_helpers.hpp +++ b/include/mapnik/ptree_helpers.hpp @@ -40,7 +40,7 @@ namespace mapnik { template -static boost::optional fast_cast(std::string const& value); +inline boost::optional fast_cast(std::string const& value); template T get(boost::property_tree::ptree const& node, std::string const& name, bool is_attribute, @@ -209,13 +209,13 @@ struct name_trait< mapnik::enumeration > }; template -boost::optional fast_cast(std::string const& value) +inline boost::optional fast_cast(std::string const& value) { return boost::lexical_cast( value ); } template <> -boost::optional fast_cast(std::string const& value) +inline boost::optional fast_cast(std::string const& value) { int result; if (mapnik::conversions::string2int(value,&result)) @@ -224,7 +224,7 @@ boost::optional fast_cast(std::string const& value) } template <> -boost::optional fast_cast(std::string const& value) +inline boost::optional fast_cast(std::string const& value) { double result; if (mapnik::conversions::string2double(value,&result)) @@ -233,7 +233,7 @@ boost::optional fast_cast(std::string const& value) } template <> -boost::optional fast_cast(std::string const& value) +inline boost::optional fast_cast(std::string const& value) { float result; if (mapnik::conversions::string2float(value,&result))