Skip to content
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

rustdoc: search for slices and arrays by type with [] #111958

Merged
merged 4 commits into from Jun 11, 2023

Conversation

notriddle
Copy link
Contributor

@notriddle notriddle commented May 25, 2023

This feature extends rustdoc to support the syntax that most users will naturally attempt to use to search for slices and arrays. Part of #60485

Function signature searches already support arrays and slices. The explicit name primitive:slice<u8> and primitive:array<u8> can be used to match a slice or array of bytes, while square brackets [u8] will match either one. Empty square brackets, [], will match any slice regardless of what it contains.

Preview:

Motivation:

When type-based search was first landed, it was directly described as "incomplete". Here's a comment from the discussion thread:

This is looking really great, nice work! I can think of a number of cases that aren't quite covered by this, but I feel like this is a great improvement regardless and it can always be iterated on so I'm fine landing with a few known cases where it may not work :)

Filling out the missing functionality is going to mean adding support for more of Rust's type expression syntax, such as slices (in this PR), tuples, references, raw pointers, function pointers, and generics.

There does seem to be demand for this sort of thing, such as this Discord message expressing regret at rustdoc not supporting tuples in search queries.

@rustbot
Copy link
Collaborator

rustbot commented May 25, 2023

r? @jsha

(rustbot has picked a reviewer for you, use r? to override)

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. labels May 25, 2023
@rustbot
Copy link
Collaborator

rustbot commented May 25, 2023

Some changes occurred in HTML/CSS/JS.

cc @GuillaumeGomez, @Folyd, @jsha

@GuillaumeGomez
Copy link
Member

It's a really nice extension! Code looks good to me. Maybe extend a bit your description of this feature (motivation and more complete explanations for user facing changes) and then let's start the FCP. :)

@notriddle
Copy link
Contributor Author

@rfcbot fcp merge

@rfcbot
Copy link

rfcbot commented May 26, 2023

Team member @notriddle has proposed to merge this. The next step is review by the rest of the tagged team members:

No concerns currently listed.

Once a majority of reviewers approve (and at most 2 approvals are outstanding), this will enter its final comment period. If you spot a major issue that hasn't been raised at any point in this process, please speak up!

See this document for info about what commands tagged team members can give me.

@rfcbot rfcbot added proposed-final-comment-period Proposed to merge/close by relevant subteam, see T-<team> label. Will enter FCP once signed off. disposition-merge This issue / PR is in PFCP or FCP with a disposition to merge it. final-comment-period In the final comment period and will be merged soon unless new substantive objections are raised. labels May 26, 2023
@rfcbot
Copy link

rfcbot commented May 29, 2023

🔔 This is now entering its final comment period, as per the review above. 🔔

@rfcbot rfcbot removed the proposed-final-comment-period Proposed to merge/close by relevant subteam, see T-<team> label. Will enter FCP once signed off. label May 29, 2023
@tgross35
Copy link
Contributor

tgross35 commented Jun 6, 2023

Could you maybe add an example in buildHelpMenu infos in src/librustdoc/html/static/js/main.js? (side note, that box could probably be made wider)

@notriddle notriddle force-pushed the notriddle/type-search-slice-array branch from 7f54028 to 646883f Compare June 7, 2023 00:28
@notriddle
Copy link
Contributor Author

image

@GuillaumeGomez
Copy link
Member

We should really add a chapter in the rustdoc book for the search features and link to it from this popover.

@rfcbot rfcbot added finished-final-comment-period The final comment period is finished for this PR / Issue. to-announce Announce this issue on triage meeting and removed final-comment-period In the final comment period and will be merged soon unless new substantive objections are raised. labels Jun 8, 2023
@rfcbot
Copy link

rfcbot commented Jun 8, 2023

The final comment period, with a disposition to merge, as per the review above, is now complete.

As the automated representative of the governance process, I would like to thank the author for their work and everyone else who contributed.

This will be merged soon.

@notriddle notriddle force-pushed the notriddle/type-search-slice-array branch from 646883f to f02d5e0 Compare June 10, 2023 21:08
@notriddle notriddle force-pushed the notriddle/type-search-slice-array branch from f02d5e0 to d3a4cd6 Compare June 10, 2023 21:08
@notriddle
Copy link
Contributor Author

@bors r=GuillaumeGomez rollup

@bors
Copy link
Contributor

bors commented Jun 11, 2023

📌 Commit d3a4cd6 has been approved by GuillaumeGomez

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jun 11, 2023
@bors
Copy link
Contributor

bors commented Jun 11, 2023

⌛ Testing commit d3a4cd6 with merge 15d4aff84530db0575d30fc0da5463a5e7bdfbeb...

@rust-log-analyzer
Copy link
Collaborator

The job x86_64-gnu-llvm-16 failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)
---- config::tests::download_ci_llvm stdout ----
downloading https://static.rust-lang.org/dist/2023-05-30/rust-std-beta-aarch64-apple-darwin.tar.xz
extracting /checkout/obj/build/cache/2023-05-30/rust-std-beta-aarch64-apple-darwin.tar.xz to /checkout/obj/build/aarch64-apple-darwin/stage0
downloading https://static.rust-lang.org/dist/2023-05-30/rustc-beta-aarch64-apple-darwin.tar.xz
thread 'config::tests::download_ci_llvm' panicked at 'status code: 1', /checkout/src/tools/build_helper/src/util.rs:16:9

failures:
    config::tests::detect_src_and_out
    config::tests::download_ci_llvm

@bors
Copy link
Contributor

bors commented Jun 11, 2023

💔 Test failed - checks-actions

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Jun 11, 2023
@notriddle
Copy link
Contributor Author

Spurious network error.

@bors retry

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jun 11, 2023
@bors
Copy link
Contributor

bors commented Jun 11, 2023

⌛ Testing commit d3a4cd6 with merge 81c02da...

@bors
Copy link
Contributor

bors commented Jun 11, 2023

☀️ Test successful - checks-actions
Approved by: GuillaumeGomez
Pushing 81c02da to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Jun 11, 2023
@bors bors merged commit 81c02da into rust-lang:master Jun 11, 2023
12 checks passed
@rustbot rustbot added this to the 1.72.0 milestone Jun 11, 2023
@notriddle notriddle deleted the notriddle/type-search-slice-array branch June 11, 2023 17:39
@rust-timer
Copy link
Collaborator

Finished benchmarking commit (81c02da): comparison URL.

Overall result: no relevant changes - no action needed

@rustbot label: -perf-regression

Instruction count

This benchmark run did not return any relevant results for this metric.

Max RSS (memory usage)

Results

This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-3.7% [-3.7%, -3.7%] 1
All ❌✅ (primary) - - 0

Cycles

This benchmark run did not return any relevant results for this metric.

Binary size

This benchmark run did not return any relevant results for this metric.

Bootstrap: 647.688s -> 647.238s (-0.07%)

@apiraino apiraino removed the to-announce Announce this issue on triage meeting label Jun 15, 2023
1715173329 added a commit to 1715173329/packages-official that referenced this pull request Aug 26, 2023
Version 1.72.0 (2023-08-24)
==========================

Language
--------

- [Replace const eval limit by a lint and add an exponential backoff warning](rust-lang/rust#103877)
- [expand: Change how `#![cfg(FALSE)]` behaves on crate root](rust-lang/rust#110141)
- [Stabilize inline asm for LoongArch64](rust-lang/rust#111235)
- [Uplift `clippy::undropped_manually_drops` lint](rust-lang/rust#111530)
- [Uplift `clippy::invalid_utf8_in_unchecked` lint](rust-lang/rust#111543)
- [Uplift `clippy::cast_ref_to_mut` lint](rust-lang/rust#111567)
- [Uplift `clippy::cmp_nan` lint](rust-lang/rust#111818)
- [resolve: Remove artificial import ambiguity errors](rust-lang/rust#112086)
- [Don't require associated types with Self: Sized bounds in `dyn Trait` objects](rust-lang/rust#112319)

Compiler
--------

- [Remember names of `cfg`-ed out items to mention them in diagnostics](rust-lang/rust#109005)
- [Support for native WASM exceptions](rust-lang/rust#111322)
- [Add support for NetBSD/aarch64-be (big-endian arm64).](rust-lang/rust#111326)
- [Write to stdout if `-` is given as output file](rust-lang/rust#111626)
- [Force all native libraries to be statically linked when linking a static binary](rust-lang/rust#111698)
- [Add Tier 3 support for `loongarch64-unknown-none*`](rust-lang/rust#112310)
- [Prevent `.eh_frame` from being emitted for `-C panic=abort`](rust-lang/rust#112403)
- [Support 128-bit enum variant in debuginfo codegen](rust-lang/rust#112474)
- [compiler: update solaris/illumos to enable tsan support.](rust-lang/rust#112039)

Refer to Rust's [platform support page][platform-support-doc]
for more information on Rust's tiered platform support.

Libraries
---------

- [Document memory orderings of `thread::{park, unpark}`](rust-lang/rust#99587)
- [io: soften ‘at most one write attempt’ requirement in io::Write::write](rust-lang/rust#107200)
- [Specify behavior of HashSet::insert](rust-lang/rust#107619)
- [Relax implicit `T: Sized` bounds on `BufReader<T>`, `BufWriter<T>` and `LineWriter<T>`](rust-lang/rust#111074)
- [Update runtime guarantee for `select_nth_unstable`](rust-lang/rust#111974)
- [Return `Ok` on kill if process has already exited](rust-lang/rust#112594)
- [Implement PartialOrd for `Vec`s over different allocators](rust-lang/rust#112632)
- [Use 128 bits for TypeId hash](rust-lang/rust#109953)
- [Don't drain-on-drop in DrainFilter impls of various collections.](rust-lang/rust#104455)
- [Make `{Arc,Rc,Weak}::ptr_eq` ignore pointer metadata](rust-lang/rust#106450)

Rustdoc
-------

- [Allow whitespace as path separator like double colon](rust-lang/rust#108537)
- [Add search result item types after their name](rust-lang/rust#110688)
- [Search for slices and arrays by type with `[]`](rust-lang/rust#111958)
- [Clean up type unification and "unboxing"](rust-lang/rust#112233)

Stabilized APIs
---------------

- [`impl<T: Send> Sync for mpsc::Sender<T>`](https://doc.rust-lang.org/nightly/std/sync/mpsc/struct.Sender.html#impl-Sync-for-Sender%3CT%3E)
- [`impl TryFrom<&OsStr> for &str`](https://doc.rust-lang.org/nightly/std/primitive.str.html#impl-TryFrom%3C%26'a+OsStr%3E-for-%26'a+str)
- [`String::leak`](https://doc.rust-lang.org/nightly/alloc/string/struct.String.html#method.leak)

These APIs are now stable in const contexts:

- [`CStr::from_bytes_with_nul`](https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)
- [`CStr::to_bytes`](https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)
- [`CStr::to_bytes_with_nul`](https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)
- [`CStr::to_str`](https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)

Cargo
-----

- Enable `-Zdoctest-in-workspace` by default. When running each documentation
  test, the working directory is set to the root directory of the package the
  test belongs to.
  [docs](https://doc.rust-lang.org/nightly/cargo/commands/cargo-test.html#working-directory-of-tests)
  [openwrt#12221](rust-lang/cargo#12221)
  [openwrt#12288](rust-lang/cargo#12288)
- Add support of the "default" keyword to reset previously set `build.jobs`
  parallelism back to the default.
  [openwrt#12222](rust-lang/cargo#12222)

Compatibility Notes
-------------------

- [Alter `Display` for `Ipv6Addr` for IPv4-compatible addresses](rust-lang/rust#112606)
- Cargo changed feature name validation check to a hard error. The warning was
  added in Rust 1.49. These extended characters aren't allowed on crates.io, so
  this should only impact users of other registries, or people who don't publish
  to a registry.
  [openwrt#12291](rust-lang/cargo#12291)

Refreshed patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
1715173329 added a commit to 1715173329/packages-official that referenced this pull request Aug 26, 2023
Version 1.72.0 (2023-08-24)
==========================

Language
--------
- [Replace const eval limit by a lint and add an exponential backoff warning](rust-lang/rust#103877)
- [expand: Change how `#![cfg(FALSE)]` behaves on crate root](rust-lang/rust#110141)
- [Stabilize inline asm for LoongArch64](rust-lang/rust#111235)
- [Uplift `clippy::undropped_manually_drops` lint](rust-lang/rust#111530)
- [Uplift `clippy::invalid_utf8_in_unchecked` lint](rust-lang/rust#111543)
- [Uplift `clippy::cast_ref_to_mut` lint](rust-lang/rust#111567)
- [Uplift `clippy::cmp_nan` lint](rust-lang/rust#111818)
- [resolve: Remove artificial import ambiguity errors](rust-lang/rust#112086)
- [Don't require associated types with Self: Sized bounds in `dyn Trait` objects](rust-lang/rust#112319)

Compiler
--------
- [Remember names of `cfg`-ed out items to mention them in diagnostics](rust-lang/rust#109005)
- [Support for native WASM exceptions](rust-lang/rust#111322)
- [Add support for NetBSD/aarch64-be (big-endian arm64).](rust-lang/rust#111326)
- [Write to stdout if `-` is given as output file](rust-lang/rust#111626)
- [Force all native libraries to be statically linked when linking a static binary](rust-lang/rust#111698)
- [Add Tier 3 support for `loongarch64-unknown-none*`](rust-lang/rust#112310)
- [Prevent `.eh_frame` from being emitted for `-C panic=abort`](rust-lang/rust#112403)
- [Support 128-bit enum variant in debuginfo codegen](rust-lang/rust#112474)
- [compiler: update solaris/illumos to enable tsan support.](rust-lang/rust#112039)

Refer to Rust's [platform support page][platform-support-doc]
for more information on Rust's tiered platform support.

Libraries
---------
- [Document memory orderings of `thread::{park, unpark}`](rust-lang/rust#99587)
- [io: soften ‘at most one write attempt’ requirement in io::Write::write](rust-lang/rust#107200)
- [Specify behavior of HashSet::insert](rust-lang/rust#107619)
- [Relax implicit `T: Sized` bounds on `BufReader<T>`, `BufWriter<T>` and `LineWriter<T>`](rust-lang/rust#111074)
- [Update runtime guarantee for `select_nth_unstable`](rust-lang/rust#111974)
- [Return `Ok` on kill if process has already exited](rust-lang/rust#112594)
- [Implement PartialOrd for `Vec`s over different allocators](rust-lang/rust#112632)
- [Use 128 bits for TypeId hash](rust-lang/rust#109953)
- [Don't drain-on-drop in DrainFilter impls of various collections.](rust-lang/rust#104455)
- [Make `{Arc,Rc,Weak}::ptr_eq` ignore pointer metadata](rust-lang/rust#106450)

Rustdoc
-------
- [Allow whitespace as path separator like double colon](rust-lang/rust#108537)
- [Add search result item types after their name](rust-lang/rust#110688)
- [Search for slices and arrays by type with `[]`](rust-lang/rust#111958)
- [Clean up type unification and "unboxing"](rust-lang/rust#112233)

Stabilized APIs
---------------
- [`impl<T: Send> Sync for mpsc::Sender<T>`](https://doc.rust-lang.org/nightly/std/sync/mpsc/struct.Sender.html#impl-Sync-for-Sender%3CT%3E)
- [`impl TryFrom<&OsStr> for &str`](https://doc.rust-lang.org/nightly/std/primitive.str.html#impl-TryFrom%3C%26'a+OsStr%3E-for-%26'a+str)
- [`String::leak`](https://doc.rust-lang.org/nightly/alloc/string/struct.String.html#method.leak)

These APIs are now stable in const contexts:

- [`CStr::from_bytes_with_nul`](https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)
- [`CStr::to_bytes`](https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)
- [`CStr::to_bytes_with_nul`](https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)
- [`CStr::to_str`](https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)

Cargo
-----
- Enable `-Zdoctest-in-workspace` by default. When running each documentation
  test, the working directory is set to the root directory of the package the
  test belongs to.
  [docs](https://doc.rust-lang.org/nightly/cargo/commands/cargo-test.html#working-directory-of-tests)
  [openwrt#12221](rust-lang/cargo#12221)
  [openwrt#12288](rust-lang/cargo#12288)
- Add support of the "default" keyword to reset previously set `build.jobs`
  parallelism back to the default.
  [openwrt#12222](rust-lang/cargo#12222)

Compatibility Notes
-------------------
- [Alter `Display` for `Ipv6Addr` for IPv4-compatible addresses](rust-lang/rust#112606)
- Cargo changed feature name validation check to a hard error. The warning was
  added in Rust 1.49. These extended characters aren't allowed on crates.io, so
  this should only impact users of other registries, or people who don't publish
  to a registry.
  [openwrt#12291](rust-lang/cargo#12291)

Refreshed patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
jefferyto pushed a commit to jefferyto/openwrt-packages that referenced this pull request Sep 21, 2023
Version 1.72.0 (2023-08-24)
==========================

Language
--------
- [Replace const eval limit by a lint and add an exponential backoff warning](rust-lang/rust#103877)
- [expand: Change how `#![cfg(FALSE)]` behaves on crate root](rust-lang/rust#110141)
- [Stabilize inline asm for LoongArch64](rust-lang/rust#111235)
- [Uplift `clippy::undropped_manually_drops` lint](rust-lang/rust#111530)
- [Uplift `clippy::invalid_utf8_in_unchecked` lint](rust-lang/rust#111543)
- [Uplift `clippy::cast_ref_to_mut` lint](rust-lang/rust#111567)
- [Uplift `clippy::cmp_nan` lint](rust-lang/rust#111818)
- [resolve: Remove artificial import ambiguity errors](rust-lang/rust#112086)
- [Don't require associated types with Self: Sized bounds in `dyn Trait` objects](rust-lang/rust#112319)

Compiler
--------
- [Remember names of `cfg`-ed out items to mention them in diagnostics](rust-lang/rust#109005)
- [Support for native WASM exceptions](rust-lang/rust#111322)
- [Add support for NetBSD/aarch64-be (big-endian arm64).](rust-lang/rust#111326)
- [Write to stdout if `-` is given as output file](rust-lang/rust#111626)
- [Force all native libraries to be statically linked when linking a static binary](rust-lang/rust#111698)
- [Add Tier 3 support for `loongarch64-unknown-none*`](rust-lang/rust#112310)
- [Prevent `.eh_frame` from being emitted for `-C panic=abort`](rust-lang/rust#112403)
- [Support 128-bit enum variant in debuginfo codegen](rust-lang/rust#112474)
- [compiler: update solaris/illumos to enable tsan support.](rust-lang/rust#112039)

Refer to Rust's [platform support page][platform-support-doc]
for more information on Rust's tiered platform support.

Libraries
---------
- [Document memory orderings of `thread::{park, unpark}`](rust-lang/rust#99587)
- [io: soften ‘at most one write attempt’ requirement in io::Write::write](rust-lang/rust#107200)
- [Specify behavior of HashSet::insert](rust-lang/rust#107619)
- [Relax implicit `T: Sized` bounds on `BufReader<T>`, `BufWriter<T>` and `LineWriter<T>`](rust-lang/rust#111074)
- [Update runtime guarantee for `select_nth_unstable`](rust-lang/rust#111974)
- [Return `Ok` on kill if process has already exited](rust-lang/rust#112594)
- [Implement PartialOrd for `Vec`s over different allocators](rust-lang/rust#112632)
- [Use 128 bits for TypeId hash](rust-lang/rust#109953)
- [Don't drain-on-drop in DrainFilter impls of various collections.](rust-lang/rust#104455)
- [Make `{Arc,Rc,Weak}::ptr_eq` ignore pointer metadata](rust-lang/rust#106450)

Rustdoc
-------
- [Allow whitespace as path separator like double colon](rust-lang/rust#108537)
- [Add search result item types after their name](rust-lang/rust#110688)
- [Search for slices and arrays by type with `[]`](rust-lang/rust#111958)
- [Clean up type unification and "unboxing"](rust-lang/rust#112233)

Stabilized APIs
---------------
- [`impl<T: Send> Sync for mpsc::Sender<T>`](https://doc.rust-lang.org/nightly/std/sync/mpsc/struct.Sender.html#impl-Sync-for-Sender%3CT%3E)
- [`impl TryFrom<&OsStr> for &str`](https://doc.rust-lang.org/nightly/std/primitive.str.html#impl-TryFrom%3C%26'a+OsStr%3E-for-%26'a+str)
- [`String::leak`](https://doc.rust-lang.org/nightly/alloc/string/struct.String.html#method.leak)

These APIs are now stable in const contexts:

- [`CStr::from_bytes_with_nul`](https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)
- [`CStr::to_bytes`](https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)
- [`CStr::to_bytes_with_nul`](https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)
- [`CStr::to_str`](https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)

Cargo
-----
- Enable `-Zdoctest-in-workspace` by default. When running each documentation
  test, the working directory is set to the root directory of the package the
  test belongs to.
  [docs](https://doc.rust-lang.org/nightly/cargo/commands/cargo-test.html#working-directory-of-tests)
  [openwrt#12221](rust-lang/cargo#12221)
  [openwrt#12288](rust-lang/cargo#12288)
- Add support of the "default" keyword to reset previously set `build.jobs`
  parallelism back to the default.
  [openwrt#12222](rust-lang/cargo#12222)

Compatibility Notes
-------------------
- [Alter `Display` for `Ipv6Addr` for IPv4-compatible addresses](rust-lang/rust#112606)
- Cargo changed feature name validation check to a hard error. The warning was
  added in Rust 1.49. These extended characters aren't allowed on crates.io, so
  this should only impact users of other registries, or people who don't publish
  to a registry.
  [openwrt#12291](rust-lang/cargo#12291)

Refreshed patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
(cherry picked from commit 846ee0b)
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
BKPepe pushed a commit to openwrt/packages that referenced this pull request Sep 21, 2023
Version 1.72.0 (2023-08-24)
==========================

Language
--------
- [Replace const eval limit by a lint and add an exponential backoff warning](rust-lang/rust#103877)
- [expand: Change how `#![cfg(FALSE)]` behaves on crate root](rust-lang/rust#110141)
- [Stabilize inline asm for LoongArch64](rust-lang/rust#111235)
- [Uplift `clippy::undropped_manually_drops` lint](rust-lang/rust#111530)
- [Uplift `clippy::invalid_utf8_in_unchecked` lint](rust-lang/rust#111543)
- [Uplift `clippy::cast_ref_to_mut` lint](rust-lang/rust#111567)
- [Uplift `clippy::cmp_nan` lint](rust-lang/rust#111818)
- [resolve: Remove artificial import ambiguity errors](rust-lang/rust#112086)
- [Don't require associated types with Self: Sized bounds in `dyn Trait` objects](rust-lang/rust#112319)

Compiler
--------
- [Remember names of `cfg`-ed out items to mention them in diagnostics](rust-lang/rust#109005)
- [Support for native WASM exceptions](rust-lang/rust#111322)
- [Add support for NetBSD/aarch64-be (big-endian arm64).](rust-lang/rust#111326)
- [Write to stdout if `-` is given as output file](rust-lang/rust#111626)
- [Force all native libraries to be statically linked when linking a static binary](rust-lang/rust#111698)
- [Add Tier 3 support for `loongarch64-unknown-none*`](rust-lang/rust#112310)
- [Prevent `.eh_frame` from being emitted for `-C panic=abort`](rust-lang/rust#112403)
- [Support 128-bit enum variant in debuginfo codegen](rust-lang/rust#112474)
- [compiler: update solaris/illumos to enable tsan support.](rust-lang/rust#112039)

Refer to Rust's [platform support page][platform-support-doc]
for more information on Rust's tiered platform support.

Libraries
---------
- [Document memory orderings of `thread::{park, unpark}`](rust-lang/rust#99587)
- [io: soften ‘at most one write attempt’ requirement in io::Write::write](rust-lang/rust#107200)
- [Specify behavior of HashSet::insert](rust-lang/rust#107619)
- [Relax implicit `T: Sized` bounds on `BufReader<T>`, `BufWriter<T>` and `LineWriter<T>`](rust-lang/rust#111074)
- [Update runtime guarantee for `select_nth_unstable`](rust-lang/rust#111974)
- [Return `Ok` on kill if process has already exited](rust-lang/rust#112594)
- [Implement PartialOrd for `Vec`s over different allocators](rust-lang/rust#112632)
- [Use 128 bits for TypeId hash](rust-lang/rust#109953)
- [Don't drain-on-drop in DrainFilter impls of various collections.](rust-lang/rust#104455)
- [Make `{Arc,Rc,Weak}::ptr_eq` ignore pointer metadata](rust-lang/rust#106450)

Rustdoc
-------
- [Allow whitespace as path separator like double colon](rust-lang/rust#108537)
- [Add search result item types after their name](rust-lang/rust#110688)
- [Search for slices and arrays by type with `[]`](rust-lang/rust#111958)
- [Clean up type unification and "unboxing"](rust-lang/rust#112233)

Stabilized APIs
---------------
- [`impl<T: Send> Sync for mpsc::Sender<T>`](https://doc.rust-lang.org/nightly/std/sync/mpsc/struct.Sender.html#impl-Sync-for-Sender%3CT%3E)
- [`impl TryFrom<&OsStr> for &str`](https://doc.rust-lang.org/nightly/std/primitive.str.html#impl-TryFrom%3C%26'a+OsStr%3E-for-%26'a+str)
- [`String::leak`](https://doc.rust-lang.org/nightly/alloc/string/struct.String.html#method.leak)

These APIs are now stable in const contexts:

- [`CStr::from_bytes_with_nul`](https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)
- [`CStr::to_bytes`](https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)
- [`CStr::to_bytes_with_nul`](https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)
- [`CStr::to_str`](https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)

Cargo
-----
- Enable `-Zdoctest-in-workspace` by default. When running each documentation
  test, the working directory is set to the root directory of the package the
  test belongs to.
  [docs](https://doc.rust-lang.org/nightly/cargo/commands/cargo-test.html#working-directory-of-tests)
  [#12221](rust-lang/cargo#12221)
  [#12288](rust-lang/cargo#12288)
- Add support of the "default" keyword to reset previously set `build.jobs`
  parallelism back to the default.
  [#12222](rust-lang/cargo#12222)

Compatibility Notes
-------------------
- [Alter `Display` for `Ipv6Addr` for IPv4-compatible addresses](rust-lang/rust#112606)
- Cargo changed feature name validation check to a hard error. The warning was
  added in Rust 1.49. These extended characters aren't allowed on crates.io, so
  this should only impact users of other registries, or people who don't publish
  to a registry.
  [#12291](rust-lang/cargo#12291)

Refreshed patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
(cherry picked from commit 846ee0b)
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
wip-sync pushed a commit to NetBSD/pkgsrc-wip that referenced this pull request Sep 24, 2023
Pkgsrc changes:
 * Adjust patches and cargo checksums to new versions.

Upstream changes:

Version 1.72.0 (2023-08-24)
==========================

Language
--------

- [Replace const eval limit by a lint and add an exponential backoff warning]
  (rust-lang/rust#103877)
- [expand: Change how `#![cfg(FALSE)]` behaves on crate root]
  (rust-lang/rust#110141)
- [Stabilize inline asm for LoongArch64]
  (rust-lang/rust#111235)
- [Uplift `clippy::undropped_manually_drops` lint]
  (rust-lang/rust#111530)
- [Uplift `clippy::invalid_utf8_in_unchecked` lint]
  (rust-lang/rust#111543)
- [Uplift `clippy::cast_ref_to_mut` lint]
  (rust-lang/rust#111567)
- [Uplift `clippy::cmp_nan` lint]
  (rust-lang/rust#111818)
- [resolve: Remove artificial import ambiguity errors]
  (rust-lang/rust#112086)
- [Don't require associated types with Self: Sized bounds in `dyn
  Trait` objects]
  (rust-lang/rust#112319)

Compiler
--------

- [Remember names of `cfg`-ed out items to mention them in diagnostics]
  (rust-lang/rust#109005)
- [Support for native WASM exceptions]
  (rust-lang/rust#111322)
- [Add support for NetBSD/aarch64-be (big-endian arm64).]
  (rust-lang/rust#111326)
- [Write to stdout if `-` is given as output file]
  (rust-lang/rust#111626)
- [Force all native libraries to be statically linked when linking
  a static binary]
  (rust-lang/rust#111698)
- [Add Tier 3 support for `loongarch64-unknown-none*`]
  (rust-lang/rust#112310)
- [Prevent `.eh_frame` from being emitted for `-C panic=abort`]
  (rust-lang/rust#112403)
- [Support 128-bit enum variant in debuginfo codegen]
  (rust-lang/rust#112474)
- [compiler: update solaris/illumos to enable tsan support.]
  (rust-lang/rust#112039)

Refer to Rust's [platform support page][platform-support-doc]
for more information on Rust's tiered platform support.

Libraries
---------

- [Document memory orderings of `thread::{park, unpark}`]
  (rust-lang/rust#99587)
- [io: soften â<80><98>at most one write attemptâ<80><99>
   requirement in io::Write::write]
  (rust-lang/rust#107200)
- [Specify behavior of HashSet::insert]
  (rust-lang/rust#107619)
- [Relax implicit `T: Sized` bounds on `BufReader<T>`, `BufWriter<T>`
  and `LineWriter<T>`]
  (rust-lang/rust#111074)
- [Update runtime guarantee for `select_nth_unstable`]
  (rust-lang/rust#111974)
- [Return `Ok` on kill if process has already exited]
  (rust-lang/rust#112594)
- [Implement PartialOrd for `Vec`s over different allocators]
  (rust-lang/rust#112632)
- [Use 128 bits for TypeId hash]
  (rust-lang/rust#109953)
- [Don't drain-on-drop in DrainFilter impls of various collections.]
  (rust-lang/rust#104455)
- [Make `{Arc,Rc,Weak}::ptr_eq` ignore pointer metadata]
  (rust-lang/rust#106450)

Rustdoc
-------

- [Allow whitespace as path separator like double colon]
  (rust-lang/rust#108537)
- [Add search result item types after their name]
  (rust-lang/rust#110688)
- [Search for slices and arrays by type with `[]`]
  (rust-lang/rust#111958)
- [Clean up type unification and "unboxing"]
  (rust-lang/rust#112233)

Stabilized APIs
---------------

- [`impl<T: Send> Sync for mpsc::Sender<T>`]
  (https://doc.rust-lang.org/nightly/std/sync/mpsc/struct.Sender.html#impl-Sync-for-Sender%3CT%3E)
- [`impl TryFrom<&OsStr> for &str`]
  (https://doc.rust-lang.org/nightly/std/primitive.str.html#impl-TryFrom%3C%26'a+OsStr%3E-for-%26'a+str)
- [`String::leak`]
  (https://doc.rust-lang.org/nightly/alloc/string/struct.String.html#method.leak)

These APIs are now stable in const contexts:

- [`CStr::from_bytes_with_nul`]
  (https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)
- [`CStr::to_bytes`]
  (https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)
- [`CStr::to_bytes_with_nul`]
  (https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)
- [`CStr::to_str`]
  (https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)

Cargo
-----

- Enable `-Zdoctest-in-workspace` by default. When running each documentation
  test, the working directory is set to the root directory of the package the
  test belongs to.
  [docs](https://doc.rust-lang.org/nightly/cargo/commands/cargo-test.html#working-directory-of-tests)
  [#12221](rust-lang/cargo#12221)
  [#12288](rust-lang/cargo#12288)
- Add support of the "default" keyword to reset previously set `build.jobs`
  parallelism back to the default.
  [#12222](rust-lang/cargo#12222)

Compatibility Notes
-------------------

- [Alter `Display` for `Ipv6Addr` for IPv4-compatible addresses]
  (rust-lang/rust#112606)
- Cargo changed feature name validation check to a hard error. The
  warning was added in Rust 1.49. These extended characters aren't
  allowed on crates.io, so this should only impact users of other
  registries, or people who don't publish to a registry.
  [#12291](rust-lang/cargo#12291)
lu-zero pushed a commit to domo-iot/packages that referenced this pull request Oct 23, 2023
Version 1.72.0 (2023-08-24)
==========================

Language
--------
- [Replace const eval limit by a lint and add an exponential backoff warning](rust-lang/rust#103877)
- [expand: Change how `#![cfg(FALSE)]` behaves on crate root](rust-lang/rust#110141)
- [Stabilize inline asm for LoongArch64](rust-lang/rust#111235)
- [Uplift `clippy::undropped_manually_drops` lint](rust-lang/rust#111530)
- [Uplift `clippy::invalid_utf8_in_unchecked` lint](rust-lang/rust#111543)
- [Uplift `clippy::cast_ref_to_mut` lint](rust-lang/rust#111567)
- [Uplift `clippy::cmp_nan` lint](rust-lang/rust#111818)
- [resolve: Remove artificial import ambiguity errors](rust-lang/rust#112086)
- [Don't require associated types with Self: Sized bounds in `dyn Trait` objects](rust-lang/rust#112319)

Compiler
--------
- [Remember names of `cfg`-ed out items to mention them in diagnostics](rust-lang/rust#109005)
- [Support for native WASM exceptions](rust-lang/rust#111322)
- [Add support for NetBSD/aarch64-be (big-endian arm64).](rust-lang/rust#111326)
- [Write to stdout if `-` is given as output file](rust-lang/rust#111626)
- [Force all native libraries to be statically linked when linking a static binary](rust-lang/rust#111698)
- [Add Tier 3 support for `loongarch64-unknown-none*`](rust-lang/rust#112310)
- [Prevent `.eh_frame` from being emitted for `-C panic=abort`](rust-lang/rust#112403)
- [Support 128-bit enum variant in debuginfo codegen](rust-lang/rust#112474)
- [compiler: update solaris/illumos to enable tsan support.](rust-lang/rust#112039)

Refer to Rust's [platform support page][platform-support-doc]
for more information on Rust's tiered platform support.

Libraries
---------
- [Document memory orderings of `thread::{park, unpark}`](rust-lang/rust#99587)
- [io: soften ‘at most one write attempt’ requirement in io::Write::write](rust-lang/rust#107200)
- [Specify behavior of HashSet::insert](rust-lang/rust#107619)
- [Relax implicit `T: Sized` bounds on `BufReader<T>`, `BufWriter<T>` and `LineWriter<T>`](rust-lang/rust#111074)
- [Update runtime guarantee for `select_nth_unstable`](rust-lang/rust#111974)
- [Return `Ok` on kill if process has already exited](rust-lang/rust#112594)
- [Implement PartialOrd for `Vec`s over different allocators](rust-lang/rust#112632)
- [Use 128 bits for TypeId hash](rust-lang/rust#109953)
- [Don't drain-on-drop in DrainFilter impls of various collections.](rust-lang/rust#104455)
- [Make `{Arc,Rc,Weak}::ptr_eq` ignore pointer metadata](rust-lang/rust#106450)

Rustdoc
-------
- [Allow whitespace as path separator like double colon](rust-lang/rust#108537)
- [Add search result item types after their name](rust-lang/rust#110688)
- [Search for slices and arrays by type with `[]`](rust-lang/rust#111958)
- [Clean up type unification and "unboxing"](rust-lang/rust#112233)

Stabilized APIs
---------------
- [`impl<T: Send> Sync for mpsc::Sender<T>`](https://doc.rust-lang.org/nightly/std/sync/mpsc/struct.Sender.html#impl-Sync-for-Sender%3CT%3E)
- [`impl TryFrom<&OsStr> for &str`](https://doc.rust-lang.org/nightly/std/primitive.str.html#impl-TryFrom%3C%26'a+OsStr%3E-for-%26'a+str)
- [`String::leak`](https://doc.rust-lang.org/nightly/alloc/string/struct.String.html#method.leak)

These APIs are now stable in const contexts:

- [`CStr::from_bytes_with_nul`](https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)
- [`CStr::to_bytes`](https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)
- [`CStr::to_bytes_with_nul`](https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)
- [`CStr::to_str`](https://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.from_bytes_with_nul)

Cargo
-----
- Enable `-Zdoctest-in-workspace` by default. When running each documentation
  test, the working directory is set to the root directory of the package the
  test belongs to.
  [docs](https://doc.rust-lang.org/nightly/cargo/commands/cargo-test.html#working-directory-of-tests)
  [openwrt#12221](rust-lang/cargo#12221)
  [openwrt#12288](rust-lang/cargo#12288)
- Add support of the "default" keyword to reset previously set `build.jobs`
  parallelism back to the default.
  [openwrt#12222](rust-lang/cargo#12222)

Compatibility Notes
-------------------
- [Alter `Display` for `Ipv6Addr` for IPv4-compatible addresses](rust-lang/rust#112606)
- Cargo changed feature name validation check to a hard error. The warning was
  added in Rust 1.49. These extended characters aren't allowed on crates.io, so
  this should only impact users of other registries, or people who don't publish
  to a registry.
  [openwrt#12291](rust-lang/cargo#12291)

Refreshed patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
disposition-merge This issue / PR is in PFCP or FCP with a disposition to merge it. finished-final-comment-period The final comment period is finished for this PR / Issue. merged-by-bors This PR was explicitly merged by bors. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

10 participants