From eba1cb4ca3af3c9359252640ac5e2792d1fa195a Mon Sep 17 00:00:00 2001 From: Andrey Mironov Date: Tue, 1 Dec 2015 14:16:41 +0300 Subject: [PATCH] dbms: FieldVisitorToString::formatFloat emit trailing dec pt [#METR-17328] --- dbms/src/Core/FieldVisitors.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dbms/src/Core/FieldVisitors.cpp b/dbms/src/Core/FieldVisitors.cpp index 8373b481fa8..c2c4832ecbf 100644 --- a/dbms/src/Core/FieldVisitors.cpp +++ b/dbms/src/Core/FieldVisitors.cpp @@ -34,10 +34,10 @@ String FieldVisitorDump::operator() (const Array & x) const String FieldVisitorToString::formatFloat(const Float64 x) { - DoubleConverter::BufferType buffer; + DoubleConverter::BufferType buffer; double_conversion::StringBuilder builder{buffer, sizeof(buffer)}; - const auto result = DoubleConverter::instance().ToShortest(x, &builder); + const auto result = DoubleConverter::instance().ToShortest(x, &builder); if (!result) throw Exception("Cannot print float or double number", ErrorCodes::CANNOT_PRINT_FLOAT_OR_DOUBLE_NUMBER);