|
wuzp
Wrong Unit? Zero Points! Compile-time checks for units, coordinate systems and points vs. vectors.
|
The default precision of isApprox() for values of the type ValueT_, which compares relatively: 1e-12 for double and 1e-5 for float. More...
#include <wuzp/core/traits.hpp>
Static Public Member Functions | |
| static constexpr ValueT_ | value () |
The default precision of isApprox() for values of the type ValueT_, which compares relatively: 1e-12 for double and 1e-5 for float.
Integers compare exactly, so their precision is 0, and long double has the precision of double, whose representation it shares with MSVC. Every arithmetic type, the value types of value matrices (see ArithmeticValue in concepts.hpp), has one, since MSVC instantiates the default arguments of isApprox() together with its class, e.g. the values, also where isApprox() is not called. The standard only instantiates them where a call uses them (https://eel.is/c++draft/temp.inst#12), as GCC and Clang do. The primary template is the case of the integers, which rejects the other types, rather than a partial specialization requires std::is_integral_v<ValueT_> struct Precision<ValueT_>, which differs from the primary template only by its constraint, so that the precisions that MSVC needs for every arithmetic type do not rely on its support of such specializations.
Definition at line 354 of file traits.hpp.
|
inlinestaticconstexpr |
Definition at line 356 of file traits.hpp.