From 9128d841f5f271a9ecde4956af3d2ff63e701df2 Mon Sep 17 00:00:00 2001 From: Jesse Beder Date: Thu, 3 Mar 2011 02:38:35 +0000 Subject: [PATCH] Set the precision of emitting float/double to 15 --- include/yaml-cpp/emitter.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/yaml-cpp/emitter.h b/include/yaml-cpp/emitter.h index f7ec3e1..bc3a31c 100644 --- a/include/yaml-cpp/emitter.h +++ b/include/yaml-cpp/emitter.h @@ -116,6 +116,7 @@ namespace YAML EmitSeparationIfNecessary(); std::stringstream str; + str.precision(15); str << value; m_stream << str.str();