Commit Graph

213571 Commits

Author SHA1 Message Date
Michael Goulet
738b0c0673 Re-enable fn trait call notation error 2022-12-20 18:31:13 +00:00
Michael Howell
168e3da812 rustdoc: prevent CSS layout of line numbers shrinking into nothing 2022-12-20 10:32:35 -07:00
bors
d6da428f34 Auto merge of #105381 - uweigand:s390x-ffi-vaarg, r=nikic
Implement va_list and va_arg for s390x FFI

Following the s390x ELF ABI and based on the clang implementation, provide appropriate definitions of va_list in library/core/src/ffi/mod.rs and va_arg handling in compiler/rustc_codegen_llvm/src/va_arg.rs.

Fixes the following test cases on s390x:
src/test/run-make-fulldeps/c-link-to-rust-va-list-fn src/test/ui/abi/variadic-ffi.rs

Fixes https://github.com/rust-lang/rust/issues/84628.
2022-12-20 17:09:11 +00:00
Chris Denton
531f3c9ee5
Bump packed_simd_2 and getrandom v0.2
Remove old versions of `cfg-if` by bumping `packed_simd_2` and `getrandom v0.2` versions

```console
> cargo update --package packed_simd_2 --package getrandom@0.2.0
    Updating crates.io index
    Removing cfg-if v0.1.10
    Updating getrandom v0.2.0 -> v0.2.8
    Updating packed_simd_2 v0.3.4 -> v0.3.8
```

`packed_simd_2` is only used as a dependency `bytecount`. The bigger jump is `getrandom@0.2.0`, but it's still semver compatible and there doesn't seem to be any worrying changes (see the [changelog](https://github.com/rust-random/getrandom/blob/master/CHANGELOG.md)). Note that this doesn't affect `getrandom@0.1.16`, which is already using the latest version of `cfg-if` (besides, there are already plans to remove that entirely).
2022-12-20 15:28:19 +00:00
Oli Scherer
ed61be60da Some ICE debugging aids 2022-12-20 15:01:37 +00:00
Oli Scherer
fedcc739c6 tracing: make flag checking less noisy 2022-12-20 15:01:37 +00:00
Oli Scherer
b2b859be8c Some track_caller additions 2022-12-20 15:01:37 +00:00
Oli Scherer
b0ed631ad4 Some hir cleanups 2022-12-20 15:01:37 +00:00
Oli Scherer
c787de3bbd Fix some ~const usage in libcore 2022-12-20 15:01:37 +00:00
Oli Scherer
872a6da935 Remove an unused function 2022-12-20 15:00:32 +00:00
Oli Scherer
f1ef038ae4 use track_caller to show where the panic is actually from 2022-12-20 14:13:29 +00:00
Nilstrieb
fb79e44df6 Remove wrapper functions for some unstable options
They are trivial and just forward to the option. Like most other
options, we can just access it directly.
2022-12-20 15:02:15 +01:00
bors
65bd2a6a73 Auto merge of #105951 - matthiaskrgr:rollup-aqxz888, r=matthiaskrgr
Rollup of 7 pull requests

Successful merges:

 - #105835 (Refactor post borrowck cleanup passes)
 - #105930 (Disable `NormalizeArrayLen`)
 - #105938 (Update coerce_unsized tracking issue from #27732 to #18598)
 - #105939 (Improve description of struct-fields GUI test)
 - #105943 (Add regression test for #102206)
 - #105944 (Add regression test for #80816)
 - #105945 (Add regression test for #57404)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2022-12-20 13:58:08 +00:00
Oli Scherer
c9588d5bf8 Hackily fix an opaque type ICE 2022-12-20 13:43:41 +00:00
Oli Scherer
e405dabf7d Some style nits 2022-12-20 13:43:11 +00:00
Oli Scherer
8b1530260c Replace a find with a loop to simplify the logic. 2022-12-20 13:42:41 +00:00
Oli Scherer
562d846ff0 Make it easier to debug where a region error was created 2022-12-20 13:42:07 +00:00
Oli Scherer
8b5a96ec45 Some tracing cleanups 2022-12-20 13:39:48 +00:00
Matthias Krüger
8db5dd4983
Rollup merge of #105945 - JohnTitor:issue-57404, r=compiler-errors
Add regression test for #57404

r? `@compiler-errors`
Closes https://github.com/rust-lang/rust/issues/57404

Signed-off-by: Yuki Okushi <jtitor@2k36.org>
2022-12-20 14:37:35 +01:00
Matthias Krüger
b149315fda
Rollup merge of #105944 - JohnTitor:issue-80816, r=compiler-errors
Add regression test for #80816

Closes #80816
r? `@compiler-errors`
Signed-off-by: Yuki Okushi <jtitor@2k36.org>
2022-12-20 14:37:34 +01:00
Matthias Krüger
d6fbe79850
Rollup merge of #105943 - JohnTitor:issue-102206, r=compiler-errors
Add regression test for #102206

Closes #102206
r? `@compiler-errors`
Signed-off-by: Yuki Okushi <jtitor@2k36.org>
2022-12-20 14:37:34 +01:00
Matthias Krüger
191a877c88
Rollup merge of #105939 - GuillaumeGomez:improve-description-gui-test, r=Dylan-DPC
Improve description of struct-fields GUI test

I moved the comment at the top of the file and clarified it a little bit.

r? `@notriddle`
2022-12-20 14:37:33 +01:00
Matthias Krüger
ced6f38c99
Rollup merge of #105938 - andersk:coerce_unsized-tracking, r=Dylan-DPC
Update coerce_unsized tracking issue from #27732 to #18598

Issue #27732 was closed as a duplicate of #18598.
2022-12-20 14:37:33 +01:00
Matthias Krüger
c3af456d6d
Rollup merge of #105930 - JakobDegen:nal-unsound, r=oli-obk
Disable `NormalizeArrayLen`

cc #105929

r? mir-opt
2022-12-20 14:37:32 +01:00
Matthias Krüger
52fe5a1cc1
Rollup merge of #105835 - tmiasko:cleanup-post-borrowck, r=JakobDegen
Refactor post borrowck cleanup passes
2022-12-20 14:37:31 +01:00
Chris Denton
b859b8b62b
Bump cfg-if to 1.0 2022-12-20 13:03:45 +00:00
bors
8a746f4ac3 Auto merge of #105940 - matthiaskrgr:rollup-ho4po1t, r=matthiaskrgr
Rollup of 5 pull requests

Successful merges:

 - #105901 (Don't panic on stable since miri is not available there)
 - #105912 (rustdoc: force pre tags to have the default line height)
 - #105914 (rustdoc: Simplify CSS for scraped code examples code blocks)
 - #105933 (Add readable rustdoc display for tvOS and watchOS)
 - #105935 (docs/test: add UI test and long-form error docs for `E0377`)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2022-12-20 10:20:27 +00:00
Yuki Okushi
8f88cecab6
Add regression test for #57404
Signed-off-by: Yuki Okushi <jtitor@2k36.org>
2022-12-20 18:52:30 +09:00
Yuki Okushi
17d7d71d94
Add regression test for #80816
Signed-off-by: Yuki Okushi <jtitor@2k36.org>
2022-12-20 18:48:02 +09:00
Yuki Okushi
a115a59cb2
Add regression test for #102206
Signed-off-by: Yuki Okushi <jtitor@2k36.org>
2022-12-20 18:24:04 +09:00
Ezra Shaw
082ca1e461
docs: add long error explanation for error E0472 2022-12-20 21:34:30 +13:00
Matthias Krüger
051c52a727
Rollup merge of #105935 - Ezrashaw:add-test+docs-for-e0377, r=GuillaumeGomez
docs/test: add UI test and long-form error docs for `E0377`
2022-12-20 08:51:16 +01:00
Matthias Krüger
9888ef77c5
Rollup merge of #105933 - taiki-e:doc-cfg, r=GuillaumeGomez
Add readable rustdoc display for tvOS and watchOS

They are currently displayed as `target_os="..."` in rustdoc, but it would be nice to have readable display like in iOS and other OSs.

<img width="487" alt="cfg" src="https://user-images.githubusercontent.com/43724913/208579395-fd5cf276-8171-47ab-bbed-23e40bb7af11.png">
2022-12-20 08:51:16 +01:00
Matthias Krüger
1abbc3f01b
Rollup merge of #105914 - GuillaumeGomez:simplify-css-examples-code-blocks, r=notriddle
rustdoc: Simplify CSS for scraped code examples code blocks

It's another approach than https://github.com/rust-lang/rust/pull/105894 for https://github.com/rust-lang/rust/pull/105823.

I simply removed the extra style added for the scraped code blocks which appears to be unneeded.

r? `@notriddle`
2022-12-20 08:51:16 +01:00
Matthias Krüger
951949c05e
Rollup merge of #105912 - notriddle:notriddle/pre-line-height, r=GuillaumeGomez
rustdoc: force pre tags to have the default line height

Fixes #105906
2022-12-20 08:51:15 +01:00
Matthias Krüger
bcb75e61ab
Rollup merge of #105901 - oli-obk:no_miri_on_stable, r=Mark-Simulacrum
Don't panic on stable since miri is not available there

fixes #105816
2022-12-20 08:51:14 +01:00
lcnr
750bf36c33 dedup assembly 2022-12-20 07:30:24 +00:00
bors
eb9e5e711d Auto merge of #105880 - Nilstrieb:make-newtypes-less-not-rust, r=oli-obk
Improve syntax of `newtype_index`

This makes it more like proper Rust and also makes the implementation a lot simpler.

Mostly just turns weird flags in the body into proper attributes.

It should probably also be converted to an attribute macro instead of function-like, but that can be done in a future PR.
2022-12-20 07:27:01 +00:00
Guillaume Gomez
babd174ace Improve description of struct-fields GUI test 2022-12-20 08:22:31 +01:00
Anders Kaseorg
8c73ce6611 Update coerce_unsized tracking issue from #27732 to #18598
Issue #27732 was closed as a duplicate of #18598.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2022-12-19 23:09:47 -08:00
Ezra Shaw
e798fdf7be
docs/test: add UI test and long-form error docs for E0377 2022-12-20 18:31:15 +13:00
bors
7f42e58eff Auto merge of #105575 - compiler-errors:impl-wf-lint, r=oli-obk
Add `IMPLIED_BOUNDS_ENTAILMENT` lint

Implements a lint (#105572) version of the hard-error introduced in #105483. Context is in that PR.

r? `@lcnr`
cc `@oli-obk` who had asked for this to be a lint first

Not sure if this needs to be an FCP, since it's a lint for now.
2022-12-20 03:52:43 +00:00
Taiki Endo
1b11ce26fa Add readable rustdoc display for tvOS and watchOS 2022-12-20 12:42:12 +09:00
Arvind Mukund
55c4164fff Correct ModFlagBehavior for Aarch64 on LLVM-15
When building with Fat LTO and BTI enabled on aarch64, the BTI is set to
`Module::Min` for alloc shim but is set to `Module::Error` for the
crate. This was fine when we were using LLVM-14 but LLVM-15 changes it's
behaviour to support for compiling with different `mbranch-protection`
flags.

Refer:
b0343a38a5
2022-12-19 19:13:17 -08:00
Jakob Degen
4251289f27 Disable NormalizeArrayLen 2022-12-19 17:38:18 -08:00
bors
c43bc13562 Auto merge of #105918 - matthiaskrgr:rollup-mmazd62, r=matthiaskrgr
Rollup of 7 pull requests

Successful merges:

 - #105801 (Realistic `Path::as_mut_os_str` doctest)
 - #105860 (Add long error docs for `E0460` and `E0457`)
 - #105895 (Test that we don't add a new kind of breaking change with TAITs)
 - #105902 (docs: improve pin docs)
 - #105910 (Update books)
 - #105913 (rustdoc: remove width-limiter from source pages, stop overriding CSS)
 - #105915 (Revert "Replace usage of `ResumeTy` in async lowering with `Context`")

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2022-12-20 01:06:52 +00:00
bors
696563efc5 Auto merge of #105905 - lqd:revert-103880, r=jackh726
Revert #103880 "Use non-ascribed type as field's type in mir"

This PR prepares a revert for #103880 to fix #105809, #105881, #105886 and others (like the duplicates of the first one), in case an actual fix can't get done today.

I've also added the MCVE from #105809. There is no MCVE for the #105881 and #105886 ICEs yet however, so there are no tests for them here, although we'll need one before relanding the original changes.

Were this PR to land, it would also reopen #96514 as it was fixed by the original PR.

Opening as draft to allow time for a possible fix.

r? `@jackh726`
2022-12-19 22:37:12 +00:00
Ulrich Weigand
eb22d70aed Implement va_list and va_arg for s390x FFI
Following the s390x ELF ABI and based on the clang implementation,
provide appropriate definitions of va_list in library/core/src/ffi/mod.rs
and va_arg handling in compiler/rustc_codegen_llvm/src/va_arg.rs.

Fixes the following test cases on s390x:
src/test/run-make-fulldeps/c-link-to-rust-va-list-fn
src/test/ui/abi/variadic-ffi.rs

Fixes https://github.com/rust-lang/rust/issues/84628.
2022-12-19 21:07:57 +01:00
Matthias Krüger
575b2a2232
Rollup merge of #105915 - andrewpollack:revert-105250-async-rm-resumety, r=tmandry
Revert "Replace usage of `ResumeTy` in async lowering with `Context`"

Reverts rust-lang/rust#105250
Fixes: #105501

Following instructions from [forge](https://forge.rust-lang.org/compiler/reviews.html#reverts).

This change introduced a breaking change that is not actionable nor relevant, and is blocking updates to our toolchain. Along with other comments on the CL marking issues that are fixed by reverts, reverting is best until these issues can be resolved

cc. `@Swatinem`
2022-12-19 20:55:00 +01:00
Matthias Krüger
d90658d1a2
Rollup merge of #105913 - notriddle:notriddle/width-limiter, r=GuillaumeGomez
rustdoc: remove width-limiter from source pages, stop overriding CSS
2022-12-19 20:55:00 +01:00