Adding cstdfloat.hpp - wheres the best place?
Folks, Christopher Kormanyos has coded up a version of cstdfloat.hpp for Boost.Math: https://github.com/boostorg/math/blob/bernoulli-tgamma/include/boost/math/to... This header is proposed for C++14, and the C language folks are doing something similar: it provides similar functionality for floating point types that <cstdint> does for integer types: Typedefs: floatN_t float_leastN_t float_fastN_t floatmax_t Macros: BOOST_FLOATN_C(x) // floating point constant of width N. BOOST_FLOAT_N_MIN BOOST_FLOAT_N_MAX BOOST_FLOAT_FASTN_C(x) BOOST_FLOAT_LEASTN_MIN BOOST_FLOAT_FASTN_MIN BOOST_FLOAT_LEASTN_MAX BOOST_FLOAT_FASTN_MAX BOOST_FLOATMAX_C(x) BOOST_FLOATMAX_MIN BOOST_FLOATMAX_MAX Where N is one of 16, 32, 64, 128 and correspond to the IEEE half, single, double and quad types respectively. So... the question is where to best place this? Does anyone object if it goes under boost/cstdfloat.hpp to sit alongside cstdint.hpp? Where should it best be documented and tested? We can obviously add it under the Math lib, but is there a better more "discoverable" place? cstdint.hpp is under integer BTW so it can't go there ;-) Thanks in advance, John.
cstdfloat.hpp for Boost.Math
This header is proposed for C++14
The C++14 proposal is here:
http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2013/n3626.pdf
On Tuesday, January 14, 2014 8:27 PM, John Maddock
participants (2)
-
Christopher Kormanyos
-
John Maddock