Commit Graph

217401 Commits

Author SHA1 Message Date
Laurențiu Nicola
cfeec8a705 Add clippy configuration section to the manual 2023-02-12 11:34:52 +02:00
bors
a14a1520a3 Auto merge of #14135 - lnicola:manual-lapce, r=lnicola
feat: Add Lapce section to the manual
2023-02-12 09:12:48 +00:00
Laurențiu Nicola
9d85161f30 Add Lapce section to the manual 2023-02-12 11:12:05 +02:00
bors
5ef76da835 Auto merge of #14133 - lnicola:changelog-version, r=lnicola
minor: Add version placeholder to changelog template

Closes #13967

This isn't great because we need to fill it in manually, but getting the version number from GitHub Actions is a bit annoying.
2023-02-12 08:57:08 +00:00
Laurențiu Nicola
240b6f7f8d Add version placeholder to changelog template 2023-02-12 10:55:49 +02:00
bors
51cb5614dd Auto merge of #105601 - BelovDV:change-rlib-with-not-stable, r=petrochenkov
Enable new rlib in non stable cases

If bundled static library uses cfg (unstable) or whole-archive (wasn't supported) bundled libs are packed even without packed_bundled_libs.

r? `@petrochenkov`
2023-02-12 07:15:27 +00:00
bors
b7089e0dd3 Auto merge of #107894 - Voultapher:improve-heapsort-fallback, r=scottmcm
Speedup heapsort by 1.5x by making it branchless

`slice::sort_unstable` will fall back to heapsort if it repeatedly fails to find a good pivot. By making the core child update code branchless it is much faster. On Zen3 sorting 10k `u64` and forcing the sort to pick heapsort, results in:

455us -> 278us
2023-02-12 03:30:10 +00:00
Michael Goulet
cca82fd997 Document PointerLike 2023-02-12 01:23:02 +00:00
bors
d094016128 Auto merge of #106677 - tbu-:pr_less_doc_hidden_pub, r=scottmcm
Remove a couple of `#[doc(hidden)] pub fn` and their `#[feature]` gates
2023-02-11 23:57:05 +00:00
Michael Howell
72b3f46b43 rustdoc: account for intra-doc links in <meta name="description"> 2023-02-11 16:10:28 -07:00
John Kåre Alsaker
80d265240b Create a single value cache for the () query key 2023-02-11 23:38:01 +01:00
bors
585f3eef26 Auto merge of #107851 - cjgillot:sroa-const, r=oli-obk
Put deaggregated statements after original constant.

Fixes https://github.com/rust-lang/rust/issues/107818
2023-02-11 20:59:18 +00:00
Vadim Petrochenkov
37a72a2e3e rustc_ast: Merge impls and reorder methods for attributes and meta items 2023-02-11 23:23:17 +04:00
Vadim Petrochenkov
0e61d3ab3f rustdoc: Remove cache for preprocessed markdown links 2023-02-11 22:27:02 +04:00
Camille GILLOT
84bb373b2a Pacify tidy. 2023-02-11 18:07:06 +00:00
bors
2b3f260e74 Auto merge of #107928 - matthiaskrgr:rollup-qnn380r, r=matthiaskrgr
Rollup of 7 pull requests

Successful merges:

 - #107657 (Add only modified subcommand for compiletest)
 - #107864 (rustdoc: clean up `write!` calls with less stuttering)
 - #107873 (Emit JSON output for the building of bootstrap itself)
 - #107895 (remove redundant clones)
 - #107897 (Reexported macros docs)
 - #107909 (rustdoc: remove redundant `if s.is_empty()` from `find_testable_code`)
 - #107912 (rustdoc: Don't resolve link to field on different variant)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2023-02-11 18:01:17 +00:00
Camille GILLOT
e80afa6501 Intern span when length is MAX_LEN with parent. 2023-02-11 17:46:22 +00:00
Guillaume Gomez
d505c5abe4 Improve JS function itemTypeFromName code a bit 2023-02-11 18:03:21 +01:00
bors
c29a00457a Auto merge of #14127 - lnicola:windows-x86, r=lnicola
feat: Build `i686-pc-windows-msvc` binaries

These have been requested a couple of times, so let's build them.
2023-02-11 16:23:56 +00:00
Matthias Krüger
c8614a7479
Rollup merge of #107912 - clubby789:doc-bad-enum-field, r=camelid,GuillaumeGomez
rustdoc: Don't resolve link to field on different variant

Fix #107903

This also gives a more specific diagnostic when the enum has any fields
2023-02-11 17:18:45 +01:00
Matthias Krüger
f95f68e619
Rollup merge of #107909 - notriddle:notriddle/register-header-empty-cond, r=camelid
rustdoc: remove redundant `if s.is_empty()` from `find_testable_code`
2023-02-11 17:18:45 +01:00
Matthias Krüger
1305119a3f
Rollup merge of #107897 - GuillaumeGomez:reexported-macros-docs, r=notriddle
Reexported macros docs

Part of #59368 (doesn't fix it, only improve the current situation a bit).

Macros were not correctly handled in reexports and the reexport attributes were not merged with the item either. This PR fixes both.

r? `@notriddle`
2023-02-11 17:18:44 +01:00
Matthias Krüger
4b7b5698a4
Rollup merge of #107895 - matthiaskrgr:cl, r=compiler-errors
remove redundant clones
2023-02-11 17:18:44 +01:00
Matthias Krüger
420e756c8a
Rollup merge of #107873 - zephaniahong:issue-107832-fix, r=albertlarsan68
Emit JSON output for the building of bootstrap itself

Fixes #107832 .
Main changes are from line 792 onwards. Other changes are due to the flake8 formatter. Let me know if I should not use the formatter.
2023-02-11 17:18:43 +01:00
Matthias Krüger
240d5e0f68
Rollup merge of #107864 - notriddle:notriddle/rustdoc-write-stutter, r=GuillaumeGomez
rustdoc: clean up `write!` calls with less stuttering
2023-02-11 17:18:43 +01:00
Matthias Krüger
585b458021
Rollup merge of #107657 - chenyukang:yukang/add-only-modified, r=albertlarsan68
Add only modified subcommand for compiletest

r? `@jyn514`

From [discussion](https://rust-lang.zulipchat.com/#narrow/stream/326414-t-infra.2Fbootstrap/topic/Add.20subcommand.20to.20retest.20all.20tests.20with.20different.20results)
2023-02-11 17:18:42 +01:00
Laurențiu Nicola
87d6107f19 Build i686-pc-windows-msvc binaries 2023-02-11 17:50:48 +02:00
bors
d78a0be9b0 Auto merge of #14125 - Veykril:inlay-fix, r=Veykril
fix: Fix bind pat inlay hints rendering for constant patterns

Fixes https://github.com/rust-lang/rust-analyzer/issues/14124
2023-02-11 15:30:46 +00:00
Lukas Wirth
5fdf640fb3 fix: Fix bind pat inlay hints rendering for constant patterns 2023-02-11 16:29:54 +01:00
bors
8dabf5da9e Auto merge of #107167 - the8472:rawvec-simpler-layout, r=thomcc
simplify layout calculations in rawvec

The use of `Layout::array` was introduced in #83706 which lead to a [perf regression](https://github.com/rust-lang/rust/pull/83706#issuecomment-1048377719).

This PR basically reverts that change since rust currently only supports stride == size types, but to be on the safe side it leaves a const-assert there to make sure this gets caught if those assumptions ever change.
2023-02-11 15:08:30 +00:00
clubby789
ef8de38c84 rustdoc: Don't resolve link to field on different variant 2023-02-11 12:28:35 +00:00
bors
5b45024487 Auto merge of #94857 - petrochenkov:doclink2, r=oli-obk
Resolve documentation links in rustc and store the results in metadata

This PR implements MCP https://github.com/rust-lang/compiler-team/issues/584.

Doc links are now resolved in rustc and stored into metadata, so rustdoc simply retrieves them through a query (local or extern),

Code that is no longer used is removed, and some code that no longer needs to be public is privatized.
The removed code includes resolver cloning, so this PR fixes https://github.com/rust-lang/rust/issues/83761.
2023-02-11 12:10:16 +00:00
Jakub Beránek
14033108cd
Print disk usage in PGO CI script 2023-02-11 10:31:09 +01:00
bors
71f6675de1 Auto merge of #107919 - Dylan-DPC:rollup-fkl9swa, r=Dylan-DPC
Rollup of 9 pull requests

Successful merges:

 - #105019 (Add parentheses properly for borrowing suggestion)
 - #106001 (Stop at the first `NULL` argument when iterating `argv`)
 - #107098 (Suggest function call on pattern type mismatch)
 - #107490 (rustdoc: remove inconsistently-present sidebar tooltips)
 - #107855 (Add a couple random projection tests for new solver)
 - #107857 (Add ui test for implementation on projection)
 - #107878 (Clarify `new_size` for realloc means bytes)
 - #107888 (revert #107074, add regression test)
 - #107900 (Zero the `REPARSE_MOUNTPOINT_DATA_BUFFER` header)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2023-02-11 09:19:07 +00:00
Lukas Bergdoll
ee0376c368 Split branches in heapsort child selection
This allows even better code-gen, cmp + adc. While also more clearly
communicating the intent.
2023-02-11 09:32:52 +01:00
bors
1623ab0246 Auto merge of #107507 - BoxyUwU:deferred_projection_equality, r=lcnr
Implement `deferred_projection_equality` for erica solver

Somewhat of a revival of #96912. When relating projections now emit an `AliasEq` obligation instead of attempting to determine equality of projections that may not be as normalized as possible (i.e. because of lazy norm, or just containing inference variables that prevent us from resolving an impl). Only do this when the new solver is enabled
2023-02-11 05:46:24 +00:00
Dylan DPC
a50c379fcd
Rollup merge of #107900 - ChrisDenton:zero-header, r=thomcc
Zero the `REPARSE_MOUNTPOINT_DATA_BUFFER` header

Makes sure the full header is correctly initialized.

Fixes #107884
2023-02-11 11:15:58 +05:30
Dylan DPC
745361d17d
Rollup merge of #107888 - lcnr:opaque-ty-validate, r=wesleywiser
revert #107074, add regression test

fixes #107346
2023-02-11 11:15:57 +05:30
Dylan DPC
dfc242220f
Rollup merge of #107878 - workingjubilee:new-size-means-bytes, r=scottmcm
Clarify `new_size` for realloc means bytes

Minor docs fix requested by https://github.com/rust-lang/rust/issues/107875
2023-02-11 11:15:57 +05:30
Dylan DPC
2228c86bad
Rollup merge of #107857 - GuillaumeGomez:ui-test-impl-projections, r=oli-obk
Add ui test for implementation on projection

The error in full can be seen in https://github.com/rust-lang/rust/pull/107263 and is part of why the PR is blocked (it still requires the approval from the team for supporting it).

r? ``@oli-obk``
2023-02-11 11:15:56 +05:30
Dylan DPC
27454012c1
Rollup merge of #107855 - compiler-errors:new-solver-random-tests, r=lcnr
Add a couple random projection tests for new solver

Self-explanatory, they're just some cases that have been on my mind in the past (especially `tests/ui/traits/new-solver/param-candidate-doesnt-shadow-project.rs`).
2023-02-11 11:15:56 +05:30
Dylan DPC
9af90ffa3c
Rollup merge of #107490 - notriddle:notriddle/rm-sidebar-tooltip, r=GuillaumeGomez
rustdoc: remove inconsistently-present sidebar tooltips

Discussed in https://rust-lang.zulipchat.com/#narrow/stream/266220-rustdoc/topic/Inconsistent.20sidebar.20tooltips/near/323565625
2023-02-11 11:15:55 +05:30
Dylan DPC
400b03ac3c
Rollup merge of #107098 - compiler-errors:pat-mismatch-fn-call, r=lcnr
Suggest function call on pattern type mismatch

Fixes #101208

This could definitely be generalized to support more suggestions in pattern matches. We can't use all of [`FnCtxt::emit_type_mismatch_suggestions`](https://doc.rust-lang.org/nightly/nightly-rustc/rustc_hir_typeck/fn_ctxt/struct.FnCtxt.html#method.emit_type_mismatch_suggestions), but it's on my to-do list to play around with more suggestions that would be productive in this position.
2023-02-11 11:15:55 +05:30
Dylan DPC
0e8f0b03cd
Rollup merge of #106001 - sdroege:glibc-skip-over-null-argv, r=ChrisDenton
Stop at the first `NULL` argument when iterating `argv`

Some C commandline parsers (e.g. GLib and Qt) are replacing already handled arguments in `argv` with `NULL` and move them to the end. That means that `argc` might be bigger than the actual number of non-`NULL` pointers in `argv` at this point.

To handle this we simply stop iterating at the first `NULL` argument.

`argv` is also guaranteed to be `NULL`-terminated so any non-`NULL` arguments after the first `NULL` can safely be ignored.

Fixes https://github.com/rust-lang/rust/issues/105999
2023-02-11 11:15:54 +05:30
Dylan DPC
0781d5dd8e
Rollup merge of #105019 - chenyukang:yukang/fix-104961-borrow, r=cjgillot
Add parentheses properly for borrowing suggestion

Fixes #104961
2023-02-11 11:15:54 +05:30
kadmin
cbd1b81bd2 Add array::map benchmarks 2023-02-11 04:23:53 +00:00
Zephaniah Ong
1057e2132e emit JSON output for building of bootstrap itself 2023-02-11 09:38:33 +08:00
base0x10
20446bd92b Update broken link in cargo style guide
Toml now uses [toml.io](https://toml.io) for released specifications
and the github repo for development. Also the old link was for the 0.4
specification, while cargo uses toml_edit, which uses toml 1.0
(reference:
https://github.com/toml-rs/toml/blob/main/crates/toml_edit/CHANGELOG.md#030---2021-09-13).
Finally the discussion of "Bare keys" vs "Quoted keys" has moved from
the `#table` section to `#keys`.
2023-02-10 23:58:25 +00:00
Michael Howell
897647b378 rustdoc: remove redundant if s.is_empty() from find_testable_code 2023-02-10 16:00:03 -07:00
bors
5a8dfd933a Auto merge of #85158 - JulianKnodt:array_const_val, r=cjgillot
Mir-Opt for copying enums with large discrepancies

I have been meaning to make this for quite a while, based off of this [hackmd](https://hackmd.io/`@ft4bxUsFT5CEUBmRKYHr7w/rJM8BBPzD).`

I'm not sure where to put this opt now that I've made it, so I'd appreciate suggestions on that!
It's also one long chain of statements, not sure if there's a more friendly format to make it.

r? `@tmiasko`
I would `r` oli but he's on leave so he suggested I `r` tmiasko or wesleywiser.
2023-02-10 21:49:31 +00:00