Created on 2016-04-14.00:00:00 last changed 78 months ago
[ 2018-06 Rapperswil Wednesday issues processing ]
This was resolved by P0415, which was adopted in Albequerque.
[ 2016-05 Issues Telecon ]
This kind of work (new feature) has been being done via papers rather than via the issues list.
Walter believes that he knows someone who would be willing to write such a paper.
This modification will allow complex-number arithmetic to be performed at compile time. From a mathematical standpoint, it is natural (and desirable) to treat complex numbers on the same footing as the reals. From a programming perspective, this change will broaden the scope in which std::complex can be used, allowing it to be smoothly incorporated into classes exploiting constexpr.
Suggested resolution: The following functions in the std::complex namespace should be made constexpr:Section [complex.member.ops]: The member (arithmetic) operators {+=, -=, /=, *=}
Section [complex.ops]: The arithmetic operators unary operators {+, -} and binary operators {+, -, /, *};
Section [complex.value.ops]: The 'value' operators abs, norm, and conj.
In terms of modification of the standard, all that is required is the insertion of the constexpr specifier in the relevant parts of:
Section [complex.syn] (the Header synopsis), together with the corresponding entries in sections [complex.ops] and [complex.value.ops].
Sections [complex], [complex.special] (class template and specializations), together with the corresponding entries in section [complex.member.ops].
History | |||
---|---|---|---|
Date | User | Action | Args |
2018-06-12 02:06:47 | admin | set | messages: + msg9900 |
2018-06-12 02:06:47 | admin | set | status: new -> resolved |
2016-05-22 15:38:38 | admin | set | messages: + msg8138 |
2016-04-14 00:00:00 | admin | create |