WPILibC++ 2024.3.2
to_chars.h File Reference
#include <array>
#include <cmath>
#include <cstdint>
#include <cstring>
#include <limits>
#include <type_traits>
#include <wpi/detail/macro_scope.h>

Go to the source code of this file.

Classes

struct  detail::dtoa_impl::diyfp
 
struct  detail::dtoa_impl::boundaries
 
struct  detail::dtoa_impl::cached_power
 

Namespaces

namespace  detail
 detail namespace with internal helper functions
 
namespace  detail::dtoa_impl
 implements the Grisu2 algorithm for binary to decimal floating-point conversion.
 

Functions

template<typename Target , typename Source >
Target detail::dtoa_impl::reinterpret_bits (const Source source)
 
template<typename FloatType >
boundaries detail::dtoa_impl::compute_boundaries (FloatType value)
 
cached_power detail::dtoa_impl::get_cached_power_for_binary_exponent (int e)
 
int detail::dtoa_impl::find_largest_pow10 (const std::uint32_t n, std::uint32_t &pow10)
 
void detail::dtoa_impl::grisu2_round (char *buf, int len, std::uint64_t dist, std::uint64_t delta, std::uint64_t rest, std::uint64_t ten_k)
 
void detail::dtoa_impl::grisu2_digit_gen (char *buffer, int &length, int &decimal_exponent, diyfp M_minus, diyfp w, diyfp M_plus)
 
void detail::dtoa_impl::grisu2 (char *buf, int &len, int &decimal_exponent, diyfp m_minus, diyfp v, diyfp m_plus)
 
template<typename FloatType >
void detail::dtoa_impl::grisu2 (char *buf, int &len, int &decimal_exponent, FloatType value)
 
JSON_HEDLEY_RETURNS_NON_NULL char * detail::dtoa_impl::append_exponent (char *buf, int e)
 appends a decimal representation of e to buf More...
 
JSON_HEDLEY_RETURNS_NON_NULL char * detail::dtoa_impl::format_buffer (char *buf, int len, int decimal_exponent, int min_exp, int max_exp)
 prettify v = buf * 10^decimal_exponent More...
 
template<typename FloatType >
JSON_HEDLEY_RETURNS_NON_NULL char * detail::to_chars (char *first, const char *last, FloatType value)
 generates a decimal representation of the floating-point number value in [first, last). More...
 

Variables

constexpr int detail::dtoa_impl::kAlpha = -60
 
constexpr int detail::dtoa_impl::kGamma = -32