mapnik::value
to_expression_string - add missing specialization for mapnik::value_integer and remove usage of std::stringstream
This commit is contained in:
parent
b086e2d20c
commit
4138a70a52
1 changed files with 7 additions and 10 deletions
|
@ -40,8 +40,6 @@
|
||||||
#include "hash_variant.hpp"
|
#include "hash_variant.hpp"
|
||||||
|
|
||||||
// stl
|
// stl
|
||||||
#include <iostream>
|
|
||||||
#include <sstream>
|
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <cmath>
|
#include <cmath>
|
||||||
|
|
||||||
|
@ -670,6 +668,13 @@ struct to_expression_string : public boost::static_visitor<std::string>
|
||||||
return "'" + utf8 + "'";
|
return "'" + utf8 + "'";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
std::string operator() (value_integer val) const
|
||||||
|
{
|
||||||
|
std::string output;
|
||||||
|
util::to_string(output,val);
|
||||||
|
return output;
|
||||||
|
}
|
||||||
|
|
||||||
std::string operator() (value_double val) const
|
std::string operator() (value_double val) const
|
||||||
{
|
{
|
||||||
std::string output;
|
std::string output;
|
||||||
|
@ -687,14 +692,6 @@ struct to_expression_string : public boost::static_visitor<std::string>
|
||||||
boost::ignore_unused_variable_warning(val);
|
boost::ignore_unused_variable_warning(val);
|
||||||
return "null";
|
return "null";
|
||||||
}
|
}
|
||||||
|
|
||||||
template <typename T>
|
|
||||||
std::string operator() (T val) const
|
|
||||||
{
|
|
||||||
std::stringstream ss;
|
|
||||||
ss << val;
|
|
||||||
return ss.str();
|
|
||||||
}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
struct to_double : public boost::static_visitor<value_double>
|
struct to_double : public boost::static_visitor<value_double>
|
||||||
|
|
Loading…
Reference in a new issue