X-Git-Url: https://git.stg.codes/stg.git/blobdiff_plain/2a1f23881feba670f3bb614e19409b5f4e90b211..474a9dc37f5085103d11cff3afa8642538f06a10:/stglibs/common.lib/common.cpp?ds=inline diff --git a/stglibs/common.lib/common.cpp b/stglibs/common.lib/common.cpp index b871b36b..15547b49 100644 --- a/stglibs/common.lib/common.cpp +++ b/stglibs/common.lib/common.cpp @@ -804,6 +804,13 @@ const std::string & x2str(uint64_t x, std::string & s) return unsigned2str(x, s); } //--------------------------------------------------------------------------- +const std::string & x2str(double x, std::string & s) +{ +char buf[256]; +s = snprintf(buf, sizeof(buf), "%f", x); +return s; +} +//--------------------------------------------------------------------------- std::string & TrimL(std::string & val) { size_t pos = val.find_first_not_of(" \t");