Details
-
Task
-
Resolution: Unresolved
-
P2: Important
-
None
-
None
-
None
Description
QTBUG-58083 asks for consistency in using the value of pi. One way to become consistent is to use C++20 std::numbers::pi or std::numbers::pi_v<T>. Since we can't depend on C++20, yet, it may be worthwhile to back-port this feature into q20.
Note that q20::numbers::pi_v<qfloat16> should also work, which means we need to specialize the variable templates for qfloat16 in qfloat16.h in either namespace std::numbers or q20::numbers, depending on __cpp_lib_math_constants.
q20::numbers::e_v<long double> is optional, but if it's absent, it must be documented as such:
// like std::numbers (except no support for long double)
Attachments
Issue Links
- covers
-
QTBUG-58083 Be consistent about the value of pi
-
- Open
-