Commit Graph

206044 Commits

Author SHA1 Message Date
Urgau 9ad2f00f6a Stabilize bench_black_box 2022-09-27 17:38:51 +02:00
bors 199fe1d169 Auto merge of #102223 - matthiaskrgr:rollup-wb1qdhk, r=matthiaskrgr
Rollup of 11 pull requests

Successful merges:

 - #101780 (Add a platform support document for Android)
 - #102044 (Remove `RtlGenRandom` (take two))
 - #102081 (Adding ignore fuchsia tests for execvp (pre_exec))
 - #102082 (Adding ignore fuchsia non-applicable commands)
 - #102146 (rustdoc: CSS prevent sidebar width change jank)
 - #102152 (Calculate `ProjectionTy::trait_def_id` for return-position `impl Trait` in trait correctly)
 - #102175 (Also require other subtrees to always build successfully)
 - #102176 (Add `llvm-dis` to the set of tools in `ci-llvm`)
 - #102188 (Update doc after renaming `fn is_zero`)
 - #102199 (Improve rustdoc GUI tests)
 - #102218 (Document some missing command-line arguments)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2022-09-24 06:55:32 +00:00
Matthias Krüger 4fc33e9443
Rollup merge of #102218 - ehuss:rustc-flags, r=JohnTitor
Document some missing command-line arguments

The rustc command-line arguments docs should document all of the stable arguments for rustc. Two were missing, `--force-warn` which was somewhat documented in the lint-levels chapter, but should also include a mention in the arguments list.  `--diagnostic-width` was stabilized in #95635, but the docs weren't updated.
2022-09-24 07:38:58 +02:00
Matthias Krüger 865e4566e7
Rollup merge of #102199 - GuillaumeGomez:improve-rustdoc-gui-tests, r=notriddle
Improve rustdoc GUI tests

I finally finished the update so we can now store values in variables and use them. It improves things nicely.

r? ``@notriddle``
2022-09-24 07:38:58 +02:00
Matthias Krüger be902e8905
Rollup merge of #102188 - flba-eb:doc_missed_at_rename, r=jyn514
Update doc after renaming `fn is_zero`

`fn is_zero` has been renamed to `fn count_is_zero` in 1b1bf24636.
This patch updates the documentation accordingly.
2022-09-24 07:38:57 +02:00
Matthias Krüger 0cd345c247
Rollup merge of #102176 - ojeda:add-llvm-dis-to-ci-llvm, r=Mark-Simulacrum
Add `llvm-dis` to the set of tools in `ci-llvm`

The LLVM disassembler is needed for the test introduced in https://github.com/rust-lang/rust/pull/97550.

Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
2022-09-24 07:38:56 +02:00
Matthias Krüger 00dfc32cad
Rollup merge of #102175 - oli-obk:miri_subtree_cleanup, r=jyn514
Also require other subtrees to always build successfully

r? ``@jyn514``
2022-09-24 07:38:56 +02:00
Matthias Krüger a842357d37
Rollup merge of #102152 - compiler-errors:issue-102140, r=fee1-dead
Calculate `ProjectionTy::trait_def_id` for return-position `impl Trait` in trait correctly

Fixes #102140
2022-09-24 07:38:56 +02:00
Matthias Krüger 9a4fe30fff
Rollup merge of #102146 - notriddle:notriddle/sidebar-jank, r=GuillaumeGomez
rustdoc: CSS prevent sidebar width change jank

This commit makes the `width` and `min-width` of the sidebar the same. They originally were when cad0fce205 added the `min-width` rule, but 6a5f8b1aef changed the `width` without changing the `min-width`, causing it to sometimes oscilate between 200 and 250 pixels depending on the main content.

# Before

[Screencast from 09-22-2022 10:25:29 AM.webm](https://user-images.githubusercontent.com/1593513/191813469-ea00f30f-6f49-40fc-9a26-e1dfd5068d2b.webm)

# After

[Screencast from 09-22-2022 10:32:20 AM.webm](https://user-images.githubusercontent.com/1593513/191813642-ae0902da-5262-403a-bbdf-995334201acb.webm)
2022-09-24 07:38:55 +02:00
Matthias Krüger 6b67b0d34f
Rollup merge of #102082 - andrewpollack:uid-ignore, r=tmandry
Adding ignore fuchsia non-applicable commands

Adding ignore fuchsia non-applicable commands

cc `@djkoloski`

r? `@tmandry`
2022-09-24 07:38:54 +02:00
Matthias Krüger 49ef55c708
Rollup merge of #102081 - andrewpollack:add-execvp-calls-ignore, r=tmandry
Adding ignore fuchsia tests for execvp (pre_exec)

Adding ignore fuchsia tests for pre_exec, which calls execvp

cc. `@djkoloski`

r? `@tmandry`
2022-09-24 07:38:54 +02:00
Matthias Krüger 3baf5f8d9a
Rollup merge of #102044 - ChrisDenton:BCrypt-system-rand, r=thomcc
Remove `RtlGenRandom` (take two)

First try to use the system preferred RNG but if that fails (e.g. due to a broken system configuration) then fallback to manually opening an algorithm handle.
2022-09-24 07:38:53 +02:00
Matthias Krüger 6fff4d9cfd
Rollup merge of #101780 - chriswailes:android-platform, r=joshtriplett
Add a platform support document for Android

r? ``@joshtriplett``
2022-09-24 07:38:52 +02:00
bors 06968954f7 Auto merge of #100845 - timvermeulen:iter_compare, r=scottmcm
Use internal iteration in `Iterator` comparison methods

Updates the `Iterator` methods `cmp_by`, `partial_cmp_by`, and `eq_by` to use internal iteration on `self`. I've also extracted their shared logic into a private helper function `iter_compare`, which will either short-circuit once the comparison result is known or return the comparison of the lengths of the iterators.

This change also indirectly benefits calls to `cmp`, `partial_cmp`, `eq`, `lt`, `le`, `gt`, and `ge`.

Unsurprising benchmark results: iterators that benefit from internal iteration (like `Chain`) see a speedup, while other iterators are unaffected.
```
 name                           before ns/iter  after ns/iter  diff ns/iter   diff %  speedup
 iter::bench_chain_partial_cmp  208,301         54,978             -153,323  -73.61%   x 3.79
 iter::bench_partial_cmp        55,527          55,702                  175    0.32%   x 1.00
 iter::bench_lt                 55,502          55,322                 -180   -0.32%   x 1.00
```
2022-09-24 04:04:46 +00:00
Eric Huss f5f69bc0bb Document some missing command-line arguments 2022-09-23 19:02:59 -07:00
bors e1c28e0c85 Auto merge of #102068 - cjgillot:erased-lifetime-print, r=eholk
Always print '_, even for erased lifetimes.

Explicit lifetime arguments are now the recommended syntax in rust 2018 and rust 2021.  This PR applies this discipline to rustc itself.
2022-09-24 01:23:17 +00:00
Chris Wailes 7ad0ac75c9 Respond to document review feedback 2022-09-23 16:14:17 -07:00
Camille GILLOT eb1ddd2573 Bless miri. 2022-09-24 00:10:28 +02:00
bors 4a14677239 Auto merge of #102192 - matthiaskrgr:rollup-0ctjzco, r=matthiaskrgr
Rollup of 7 pull requests

Successful merges:

 - #102094 (Add missing documentation for `bool::from_str`)
 - #102115 (Add examples to `bool::then` and `bool::then_some`)
 - #102134 (Detect panic strategy using `rustc --print cfg`)
 - #102137 (Don't convert valtree to constvalue during normalization)
 - #102148 (add regression test for miri issue 2433)
 - #102158 (rustdoc: clean up CSS/DOM for deprecation warnings)
 - #102177 (Fix a typo in `std`'s root docs)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2022-09-23 16:44:06 +00:00
Camille GILLOT 9b83e316c8 Bless clippy. 2022-09-23 18:42:14 +02:00
Camille GILLOT 8077d03b3f Bless 32bit ui. 2022-09-23 18:42:14 +02:00
Camille GILLOT 8de8115262 Bless pretty tests. 2022-09-23 18:42:14 +02:00
Camille GILLOT f11499189e Bless cgu test. 2022-09-23 18:42:14 +02:00
Camille GILLOT aac2c7ddd8 Always print '_, even for erased lifetimes. 2022-09-23 18:42:14 +02:00
Michael Howell cd481542df rustdoc: fix GUI tests to deal with slightly changed width 2022-09-23 09:18:07 -07:00
Guillaume Gomez d30cb5b663 Improve GUI tests by using variables 2022-09-23 18:12:37 +02:00
Guillaume Gomez a4046e93e2 Update browser-ui-test version to 0.11.0 2022-09-23 18:12:23 +02:00
Michael Howell e3cb0a84c2 rustdoc: add regression test for sidebar width jank 2022-09-23 08:35:14 -07:00
Michael Howell ee8e0bda34 rustdoc: CSS prevent sidebar width change jank
This commit makes the `width` and `min-width` of the sidebar the same. They
originally were when cad0fce205 added the
`min-width` rule, but 6a5f8b1aef changed the
width without changing the `min-width`, causing it to sometimes oscilate
between 200 and 250 pixels depending on the main content.
2022-09-23 08:35:14 -07:00
Matthias Krüger dfe045ad71
Rollup merge of #102177 - inquisitivecrystal:std-doc-typo, r=Dylan-DPC
Fix a typo in `std`'s root docs

Remarkably, this typo has been present for *seven years.* I was so surprised that I reread the text five times and then asked people on the rust Zulip to double-check. :)
2022-09-23 15:40:23 +02:00
Matthias Krüger 6d6d89b08b
Rollup merge of #102158 - notriddle:notriddle/stab-p, r=GuillaumeGomez
rustdoc: clean up CSS/DOM for deprecation warnings

Preview: https://notriddle.com/notriddle-rustdoc-test/stab-p/std/macro.try.html
2022-09-23 15:40:23 +02:00
Matthias Krüger 0d0186939b
Rollup merge of #102148 - RalfJung:miri-test, r=oli-obk
add regression test for miri issue 2433

Adding this here because the test needs to be run with debug assertions enabled to be sure so I had to run it in the rustc workspace.

Cc https://github.com/rust-lang/miri/issues/2433
r? ``@oli-obk``
2022-09-23 15:40:22 +02:00
Matthias Krüger 3a8bad98d7
Rollup merge of #102137 - b-naber:lazy-const-val-conversion, r=lcnr
Don't convert valtree to constvalue during normalization

r? ``@lcnr``
2022-09-23 15:40:22 +02:00
Matthias Krüger 3de0d678f8
Rollup merge of #102134 - flba-eb:master, r=bjorn3
Detect panic strategy using `rustc --print cfg`

Instead of relying on a command line parameter, detect if a target is able to unwind or not.
Ignore tests that require unwinding on targets that don't support it.

I did not find any place where the removed parameter has been used, but it feels a bit risky as
I'm new to this test framework.

r? bjorn3
2022-09-23 15:40:21 +02:00
Matthias Krüger 6b001f3d68
Rollup merge of #102115 - Alfriadox:master, r=thomcc
Add examples to `bool::then` and `bool::then_some`

Added examples to `bool::then` and `bool::then_some` to show the distinction between the eager evaluation of `bool::then_some` and the lazy evaluation of `bool::then`.
2022-09-23 15:40:20 +02:00
Matthias Krüger 986fc4b5d2
Rollup merge of #102094 - GuillaumeGomez:bool-from-str-missing-docs, r=scottmcm
Add missing documentation for `bool::from_str`

Fixes #101870.
2022-09-23 15:40:20 +02:00
bors 9a963e3bad Auto merge of #102056 - b-naber:unevaluated, r=lcnr
Introduce mir::Unevaluated

Previously the distinction between unevaluated constants in the type-system and in mir was not explicit and a little confusing. Probably better to introduce its own type for that.

r? `@lcnr`
2022-09-23 13:39:11 +00:00
b-naber a705e65605 rename Unevaluated to UnevaluatedConst 2022-09-23 14:27:34 +02:00
b-naber ded3edac9a fix test 2022-09-23 14:25:30 +02:00
Florian Bartels 8eeeac69db Update doc after renaming fn is_zero
`fn is_zero` has been renamed to `fn count_is_zero` in
1b1bf24636.
This patch updates the documentation accordingly.
2022-09-23 14:16:35 +02:00
bors 4d44e09cb1 Auto merge of #102165 - matthiaskrgr:rollup-n5oquhe, r=matthiaskrgr
Rollup of 8 pull requests

Successful merges:

 - #100734 (Split out async_fn_in_trait into a separate feature)
 - #101664 (Note if mismatched types have a similar name)
 - #101815 (Migrated the rustc_passes annotation without effect diagnostic infrastructure)
 - #102042 (Distribute rust-docs-json via rustup.)
 - #102066 (rustdoc: remove unnecessary `max-width` on headers)
 - #102095 (Deduplicate two functions that would soon have been three)
 - #102104 (Set 'exec-env:RUST_BACKTRACE=0' in const-eval-select tests)
 - #102112 (Allow full relro on powerpc64-unknown-linux-gnu)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2022-09-23 09:33:23 +00:00
inquisitivecrystal a0eb46788a Fix a typo in `std`'s root docs 2022-09-23 01:45:43 -07:00
Miguel Ojeda cb8a9c496f Add `llvm-dis` to the set of tools in `ci-llvm`
The LLVM disassembler is needed for the test introduced in
https://github.com/rust-lang/rust/pull/97550.

Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
2022-09-23 10:19:59 +02:00
Florian Bartels ccd19c7e9e Repair stderr test result to added line 2022-09-23 10:10:07 +02:00
Oli Scherer 7ed999b616 Also require other subtrees to always build successfully 2022-09-23 08:03:10 +00:00
Florian Bartels 0be3cc8234 ignore test cases when checking emscripten 2022-09-23 09:41:12 +02:00
bors bc4d574ff2 Auto merge of #102150 - matthiaskrgr:rollup-6xmd8f3, r=matthiaskrgr
Rollup of 10 pull requests

Successful merges:

 - #102113 (OpTy: fix a method taking self rather than &self)
 - #102118 (rustdoc: clean up line numbers on code examples)
 - #102123 (Add note to clippy::non_expressive_names doc)
 - #102125 (rustdoc: remove no-op CSS `.content .item-info { position: relative }`)
 - #102127 (Use appropriate variable names)
 - #102128 (Const unification is already infallible, remove the error handling logic)
 - #102133 (Use valtrees for comparison)
 - #102135 (Improve some AllTypes fields name)
 - #102144 (Extend const_convert with const {FormResidual, Try} for ControlFlow.)
 - #102147 (rustdoc: remove no-op CSS `.location:empty { border: none }`)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2022-09-23 06:52:39 +00:00
Florian Bartels 10f3657936 Adapt test results 2022-09-23 08:19:58 +02:00
Florian Bartels 0b0027fd2e Restore ignore tag
This test case actually requires std::process.
2022-09-23 08:19:58 +02:00
Florian Bartels 7bfbaa3881 Detect panic strategy using `rustc --print cfg`
Instead of relying on a command line parameter, detect if a target
is able to unwind or not.
Ignore tests that require unwinding on targets that don't support it.
2022-09-23 08:19:58 +02:00