Skip to content

Commit c835b38

Browse files
committed
Use from_chars for float point types
1 parent c3be6ec commit c835b38

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

src/lib/pq/result_traits.cpp

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
#include <tao/pq/binary.hpp>
1313
#include <tao/pq/internal/from_chars.hpp>
1414
#include <tao/pq/internal/resize_uninitialized.hpp>
15-
#include <tao/pq/internal/strtox.hpp>
1615

1716
namespace tao::pq
1817
{
@@ -128,17 +127,17 @@ namespace tao::pq
128127

129128
auto result_traits< float >::from( const char* value ) -> float
130129
{
131-
return internal::strtof( value );
130+
return internal::from_chars< float >( value );
132131
}
133132

134133
auto result_traits< double >::from( const char* value ) -> double
135134
{
136-
return internal::strtod( value );
135+
return internal::from_chars< double >( value );
137136
}
138137

139138
auto result_traits< long double >::from( const char* value ) -> long double
140139
{
141-
return internal::strtold( value );
140+
return internal::from_chars< long double >( value );
142141
}
143142

144143
auto result_traits< binary >::from( const char* value ) -> binary

0 commit comments

Comments
 (0)