New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
P2540 Empty Product for certain Views #1202
Comments
Was seen by SG9 (Ranges) on 2022-03-14 (Full Minutes) PollsPOLL: We support forwarding the change proposed in P2540R1 to LEWG.
Attendance: 11 # of Authors: 1 Author Position: SF Outcome: Consensus in favor SummaryR1 of the paper (which includes minor fixes, described in minutes) was forwarded to LWEG. |
Paper was discussed in LEWG on March 15th 2022 (Full Minutes) 2022-03-15 Library Evolution TeleconP2540R1: Empty Product for certain Views Chair: Inbal Levi Champion: Steve Downey Minute Taker: Mark Hoemmen SummarySome discussion on Zip behaviour. R1 of the paper was forwarded to C++23 (as a bug fix). POLL: We support adopting the change proposed in [P2540R1] (Empty Product for certain Views) for C++23 with priority 2 (to be approved by LEWG electronic poll).
Attendance: 25 # of Authors: 1 Author Position: SF Outcome: Strong consensus in favor OutcomeR1 of the paper was forwarded to electronic polling for C++23, with priority 2. |
P2540R1 Empty Product for certain Views (Steve Downey) |
Contrary to what R1 suggests, there is no contradiction between defining Let A be a tuple of tuples, and let’s denote the length of a tuple x by |x|, and the i-th element of x by x[i]. On one hand, we have that
for all k where for all j, A[j][k] exists. It’s clear to see that zip over an empty tuple is an infinite tuple of empty tuples, and this is the identity element of that operation, up to isomorphism. We can also define the lexicographical product as:
for tuples of integers k where 0 ≤ k[i] < |A[i]| for all 0 ≤ i < |A|. If A is an empty tuple of tuples, k is likewise an empty tuple of indices, and the above only defines lex(A)[0], because the indexing expression is the empty sum. As such, |lex(A)| = 1. However, if we then appropriately define the diagonal index as
for integer k, then we see that if A is the empty tuple, then diag(A)[k] is also the empty sum, and therefore zero, for all k. So even though the empty lexicographical product is a singleton, picking the diagonal of that product is going to repeatedly pick its only element, and the identity
is maintained even for empty A. ∎ If you want to define |
2022-05 Library Evolution Electronic Poll OutcomesPOLL: Send [P2540R0] Empty Product For Certain Views to Library Working Group for C++23, classified as an improvement of an existing feature ([P0592R4] bucket 2 item).
Weak consensus in favor. |
Details from 2022-07-01 review https://wiki.edg.com/bin/view/Wg21telecons2022/P2540-20220701 poll: put p2540r1 into C++23 assuming p2374 is on voted in
|
This has been applied. |
P2540R0 Empty Product for certain Views (Steve Downey)
The text was updated successfully, but these errors were encountered: