[Motions 2026 03 lwg 1] P4145R0 C++ Standard Library Ready Issues#8926
[Motions 2026 03 lwg 1] P4145R0 C++ Standard Library Ready Issues#8926
Conversation
…ained by const Pattern
[atomics.ref.ops]p3 Added "," to match wording added in p1.
|
I have added "fixes cplusplus/nbballot" links in the initial comment of this pull request. It would be good to amend the corresponding commits with our usual "Fixes NB ... (C++26 CD)." text (examples all over "git log"). |
c3db190 to
1ec13a4
Compare
Fixes NB GB 05-129 (C++26 CD).
…only concept duplication Fixes NB US 151-242 (C++26 CD).
…r parallel algorithms
…the difference type is also a sentinel type
…ng (data_handle_type, mapping_type, accessor_type) and the corresponding constructor
…() member functions of std::filesystem::path are misnamed Fixes NB US 189-304 (C++26 CD).
Fixes NB US 176-280 (C++26 CD).
[tab:time.format.spec],[tab:time.parse.spec] Fixed wording and formatting in examples
…td::basic_string on some platforms
…[] specification
Fixes NB US 157-255 (C++26 CD).
…nstant_array and related functions
Fixes NB US 152-243, PL-008 (C++26 CD).
1ec13a4 to
076fc37
Compare
| if the rounding style is to the nearest representable value; | ||
| %FIXME: The wording "equally near" seems problematic. | ||
| if there are two equally near such values, | ||
| %FIXME: Can multiple values have an "even least significant digit"? Or none at all? |
There was a problem hiding this comment.
I believe there's at least one such value. Although when the radix of the floating-point type is odd (which is theoretically permitted but doesn't seem present in any implementation), there may be two.
There was a problem hiding this comment.
The wording is fine; I don't see any problem with the term "equally near". I could have phrased it as "equidistant" but that seemed too fancy.
An obvious example of where the "to even" part kicks in is when you divide the smallest possible float value by two. Zero and the subnormal minimum are equally near, and you disambiguate by choosing the number with the even least significant digit, which is zero. You get the same ambiguity halfway between all adjacent numbers with equal exponent at least.
The really interesting case is when even the "to even" disambiguation isn't sufficient 😄 I'm not sure about odd radix, but for even radix, this only occurs for floating-point types with a single digit mantissa digit. This case is deliberately left as a wording hole though in order to not mandate more than C's FLT_ROUNDS mandates. Implementers know what to do anyway.
There was a problem hiding this comment.
If there can be more than 1 "equally near" values with "even least significant digit"s, then we can't chose "the one with an even least significant digit".
There was a problem hiding this comment.
Okay yeah that's true. I think you have to explicitly spell out the ambiguity instead of acting as if there was none for this not to be a wording defect. That belongs outside this PR and either in a follow-up editorial fix or LWG issue though, unless the fix is really obvious, which it isn't.
If you wanted to be explicit about the remaining ambiguity, you would either need to go full roundTiesToEven as per ISO/IEC 60559 and disambiguate according to that (stricter than C), or leave it implementation-defined (imposes documentation requirement), or unspecified (may be non-deterministic), and which one to choose isn't remotely obvious or editorial.
|
The fourth commit in the series (fd289eb) says "CWG" instead of "LWG" in the commit log. |
| of offset from \tcode{\%EC} (year only). | ||
| \begin{tailexample} | ||
| \begin{codeblock} | ||
| cout << format("{:%C %y}", -1976y); // prints \tcode{-20 76} |
There was a problem hiding this comment.
The issue didn't ask for a codeblock, so this is an editorial change.
| the locale's alternative representation. | ||
| \begin{tailexample} | ||
| \begin{codeblock} | ||
| year y; |
There was a problem hiding this comment.
This is also an editorial change, the issue didn't ask for a codeblock.
| \rSec4[mdspan.sub.canonical]{\tcode{submdspan} slice canonicalization} | ||
|
|
||
| \indexlibraryglobal{submdspan_canonicalize_slices}% | ||
| %FIXME: "Slices" is used instead of "SliceSpecifiers" in the synopsis declaration. |
There was a problem hiding this comment.
This should be filed as an editorial issue on github, rather than as a FIXME comment in the source.
| Let $P$ be | ||
| \begin{itemize} | ||
| \item | ||
| the template parameter object\iref{temp.param} |
There was a problem hiding this comment.
I was confused why the surrounding context didn't match what was in the issue, but it was changed by a091468
jwakely
left a comment
There was a problem hiding this comment.
I added a few minor comments but everything looks correct. Nice work, Dawn!
Fixes #8835.
Also fixes cplusplus/nbballot#708
Also fixes cplusplus/nbballot#814
Also fixes cplusplus/nbballot#879
Also fixes cplusplus/nbballot#855
Also fixes cplusplus/nbballot#830
Notes: