Update POSIX edition links#158505
Conversation
|
cc @rust-lang/miri |
|
r? @Darksonn rustbot has assigned @Darksonn. Use Why was this reviewer chosen?The reviewer was selected based on:
|
| @@ -714,7 +714,7 @@ trait EvalContextPrivExt<'tcx>: MiriInterpCxExt<'tcx> { | |||
| // "in the past" fire before any other thread can take an action. This ensures that for | |||
| // `pthread_cond_timedwait`, "an error is returned if [...] the absolute time specified by | |||
| // abstime has already been passed at the time of the call". | |||
| // <https://pubs.opengroup.org/onlinepubs/9699919799/functions/pthread_cond_timedwait.html> | |||
| // <https://pubs.opengroup.org/onlinepubs/9799919799/functions/pthread_cond_timedwait.html> | |||
There was a problem hiding this comment.
Doesn't this risk causing a dangling reference since whatever quote or behavior the text was referring to might have gotten changed in the latest version?
There was a problem hiding this comment.
That is a risk. I manually checked all links with anchors, but not all plain links (without anchors). In this case the comment helpfully gives us a quote
"an error is returned if [...] the absolute time specified by abstime has already been passed at the time of the call"
The pthread_cond_timedwait() function shall be equivalent to pthread_cond_wait(), except that an error is returned if the absolute time specified by abstime passes (that is, system time equals or exceeds abstime) before the condition cond is signaled or broadcasted, or if the absolute time specified by abstime has already been passed at the time of the call. When such timeouts occur, pthread_cond_timedwait() shall nonetheless release and re-acquire the mutex referenced by mutex, and may consume a condition signal directed concurrently at the condition variable.
The pthread_cond_clockwait() function shall be equivalent to pthread_cond_wait(), except that an error is returned if the absolute time specified by abstime as measured against the clock indicated by clock_id passes (that is, the current time measured by that clock equals or exceeds abstime) before the condition cond is signaled or broadcasted, or if the absolute time specified by abstime has already been passed at the time of the call. Implementations shall support passing CLOCK_REALTIME and CLOCK_MONOTONIC to pthread_cond_clockwait() as the clock_id argument. When such timeouts occur, pthread_cond_clockwait() shall nonetheless release and re-acquire the mutex referenced by mutex, and may consume a condition signal directed concurrently at the condition variable.
The text changed a bit, but I read them to carry equivalent context. I think if there's a problem with updating the links, it would possibly need a code fix/change (as it would mean the spec changed, but the code didn't follow it).
There was a problem hiding this comment.
So in other words, reviewing this PR requires carefully checking for each link you changed whether it still provides the right kind of context. That's quite a lot of work. I am not convinced it's worth the effort -- personally I don't have the spare review capacity to review PRs like this that are a lot of effort for little benefit. But I'm not the assigned reviewer, we can wait what @Darksonn says.
But for the Miri side, I am the main reviewer, and I don't think this PR provides enough benefit to justify the risk of semantically dangling references. So please remove the Miri changes.
There was a problem hiding this comment.
Heard. Thanks for the review and for maintaining MIRI. I'll remove the MIRI commit.
I got the idea of doing this from my work on another doc PR #158574. There was an old link in the same source file, but I wasn't otherwise touching those docs. It felt wrong to standardize everything on the old edition. It also seemed somewhat unclear if updating that edition in the same PR was okay or not. I chose to leave it and update all of them at once in this PR.
I see a value in standardization. When there's divergence, programmers are primed to see intent in it. Part of me sending this PR is to answer "are these old on purpose or by accident." With the theory that others just hadn't noticed and updated them. Being intentionally old because they are point-in-time references is a reasonable maintenance trade-off.
I would still like to see them updated in Rust (if not in miri). I'm open to doing more legwork if it can help (like leaving more comments as I did here, walking through the check). I just didn't want to start off with that, as otherwise it could be a bit overwhelming. Also open to breaking up the review burden into more manageable chunks with multiple commits or PRs. I just didn't want y'all to feel like I was trying to game my commit numbers.
This comment has been minimized.
This comment has been minimized.
Looks unrelated to my (docs only) change, seems intermittent. |
0f08d27 to
68d0219
Compare
This comment has been minimized.
This comment has been minimized.
Comments and doc links across std, core, and a process test referenced the older issue 7 (2018 edition) of the POSIX spec, with one link still on issue 6. Point them all at the current issue 8 (2024 edition, IEEE Std 1003.1-2024) under onlinepubs/9799919799, and normalize the `9799919799.2024edition` URL variant to the canonical path. Links that carry a section anchor were verified against the 2024 edition, since section numbering shifts between editions: - Pathname Resolution moved from 4.13 (tag_04_13) to 4.16 (tag_04_16) - Field Splitting moved from tag_18_06_05 to tag_19_06_05 - LC_CTYPE (tag_07_03_01) was unchanged CI's linkchecker only validates intra-doc links, not external URLs, so each page and anchor was checked by hand.
68d0219 to
e919f70
Compare
|
This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed. Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers. |
…on, r=Darksonn Update POSIX edition links Comments that reference https://pubs.opengroup.org point to issue 7 (the 2018 edition of IEEE Std 1003.1-2017), with one link still on the older issue 6. The latest issue is 8 (the 2024 edition, IEEE Std 1003.1-2024). From https://www.opengroup.org/austin/papers/posix_faq.html: > Q3. What is the latest version of POSIX.1? > > The 1003.1-2024 standard was published in June 2024. The standard is > formally known as: IEEE Std 1003.1-2024 The Open Group Technical > Standard Base Specifications, Issue 8 Issue 8 lives at https://pubs.opengroup.org/onlinepubs/9799919799/. This PR points all older-edition links to issue 8. Most links are a straight edition bump, but links with a section anchor needed their anchor rechecked, because section numbering shifts between editions. Verified against the 2024 edition: - Pathname Resolution moved from 4.13 (`tag_04_13`) to 4.16 (`tag_04_16`) - Field Splitting moved from `tag_18_06_05` to `tag_19_06_05` - LC_CTYPE (`tag_07_03_01`) was unchanged The Miri changes (`src/tools/miri/`) are kept in a separate commit since that's a synced subtree. I'm happy to move them to a `rust-lang/miri` PR if preferred.
…uwer Rollup of 12 pull requests Successful merges: - #156976 (enable eager `param_env` norm in new solver) - #158537 (Add `std::io::cursor::WriteThroughCursor`) - #158540 (Move `std::io::Seek` to `core::io`) - #157820 (consider subtyping when checking if an infer var is sized) - #158505 (Update POSIX edition links) - #158853 (Fix typo for link on nto-qnx.md) - #157466 (Better error message when bare type in impl parameter list) - #157966 (Emit a suggestion to cast the never type into a concrete type when it fails to satisfy an `impl Trait` bound) - #158381 (Expose debug scope of statement and terminator in rustc_public) - #158405 (rustc_target: Add ARMv8-M related target features) - #158770 (Weaken guarantee for `From<legacy::RangeInclusive> for RangeInclusive`) - #158820 (Fix rustdoc ICE on deprecated note in inlined re-export chain)
Rollup merge of #158505 - schneems:schneems/bump-posix-edition, r=Darksonn Update POSIX edition links Comments that reference https://pubs.opengroup.org point to issue 7 (the 2018 edition of IEEE Std 1003.1-2017), with one link still on the older issue 6. The latest issue is 8 (the 2024 edition, IEEE Std 1003.1-2024). From https://www.opengroup.org/austin/papers/posix_faq.html: > Q3. What is the latest version of POSIX.1? > > The 1003.1-2024 standard was published in June 2024. The standard is > formally known as: IEEE Std 1003.1-2024 The Open Group Technical > Standard Base Specifications, Issue 8 Issue 8 lives at https://pubs.opengroup.org/onlinepubs/9799919799/. This PR points all older-edition links to issue 8. Most links are a straight edition bump, but links with a section anchor needed their anchor rechecked, because section numbering shifts between editions. Verified against the 2024 edition: - Pathname Resolution moved from 4.13 (`tag_04_13`) to 4.16 (`tag_04_16`) - Field Splitting moved from `tag_18_06_05` to `tag_19_06_05` - LC_CTYPE (`tag_07_03_01`) was unchanged The Miri changes (`src/tools/miri/`) are kept in a separate commit since that's a synced subtree. I'm happy to move them to a `rust-lang/miri` PR if preferred.
|
Thanks @darkson! |
Comments that reference https://pubs.opengroup.org point to issue 7 (the 2018 edition of IEEE Std 1003.1-2017), with one link still on the older issue 6. The latest issue is 8 (the 2024 edition, IEEE Std 1003.1-2024). From https://www.opengroup.org/austin/papers/posix_faq.html:
Issue 8 lives at https://pubs.opengroup.org/onlinepubs/9799919799/.
This PR points all older-edition links to issue 8.
Most links are a straight edition bump, but links with a section anchor needed their anchor rechecked, because section numbering shifts between editions. Verified against the 2024 edition:
tag_04_13) to 4.16 (tag_04_16)tag_18_06_05totag_19_06_05tag_07_03_01) was unchangedThe Miri changes (
src/tools/miri/) are kept in a separate commit since that's a synced subtree. I'm happy to move them to arust-lang/miriPR if preferred.