Michael Goulet
01d784131f
Make trait/impl where clause mismatch on region error a bit more actionable
2022-12-28 18:09:27 +00:00
Eric Huss
120d4fd09c
Remove CraftSpider from review rotation
...
CraftSpider was removed from the rustdoc team in https://github.com/rust-lang/team/pull/897 and can no longer be assigned.
2022-12-28 10:08:48 -08:00
Nilstrieb
9067e4417e
Rename Rptr
to Ref
in AST and HIR
...
The name makes a lot more sense, and `ty::TyKind` calls it `Ref` already
as well.
2022-12-28 18:52:36 +01:00
Michael Howell
9221e43313
rustdoc: remove unnecessary .tooltip::after { text-align: center }
...
This doesn't have an effect, since these tooltip are only one line anyway.
2022-12-28 10:48:15 -07:00
Florian Bartels
04a6f22f79
Catch panics in destruction of TLS values
...
`destroy_value` is/can be called from C code (libc). Unwinding
from Rust to C code is undefined behavior, which is why unwinding
is caught here.
2022-12-28 18:32:41 +01:00
bors
be3ed4fdcd
Auto merge of #2744 - RalfJung:json, r=RalfJung
...
support using a JSON target file
Fixes https://github.com/rust-lang/miri/issues/2053
2022-12-28 17:01:52 +00:00
Ralf Jung
dfe1898437
no need to do a no_std build for wasi
2022-12-28 18:01:20 +01:00
Ralf Jung
40d65f0152
test using a JSON target file
2022-12-28 18:01:20 +01:00
bors
270c94e484
Auto merge of #106215 - matthiaskrgr:rollup-53r89ww, r=matthiaskrgr
...
Rollup of 6 pull requests
Successful merges:
- #106028 (docs/test: add UI test and long-form error docs for `E0461`)
- #106172 (Suggest `impl Iterator` when possible for `_` return type)
- #106173 (Deduplicate `op` methods)
- #106176 (Recover `fn` keyword as `Fn` trait in bounds)
- #106194 (rustdoc: combine common sidebar background color CSS rules)
- #106199 (Silence knock-down errors on `[type error]` bindings)
Failed merges:
r? `@ghost`
`@rustbot` modify labels: rollup
2022-12-28 17:00:00 +00:00
Nilstrieb
31b490d8ba
Add enum for find_width_map_from_snippet
...
This makes the relationship between the vec and the boolean clearer.
2022-12-28 17:43:35 +01:00
Nilstrieb
e6c02aad93
Improve heuristics whether format_args
string is a source literal
...
Previously, it only checked whether there was _a_ literal at the span of
the first argument, not whether the literal actually matched up. This
caused issues when a proc macro was generating a different literal with
the same span.
This requires an annoying special case for literals ending in `\n`
because otherwise `println` wouldn't give detailed diagnostics anymore
which would be bad.
2022-12-28 17:43:18 +01:00
Ralf Jung
fbd6a69937
bump dependencies
2022-12-28 17:21:20 +01:00
Ralf Jung
4fa51925fa
print sysroot build failure error
2022-12-28 17:18:14 +01:00
Guillaume Gomez
aa20f885c4
Add GUI test for scraped examples colors
2022-12-28 17:15:09 +01:00
Guillaume Gomez
c3eb202a61
Migrate scraped examples higlight CSS to variables
2022-12-28 17:14:17 +01:00
Albert Larsan
cb7c8993b9
Clarify catch_unwind docs about panic hooks
...
Makes it clear from catch_unwind docs that the panic hook will be called
before the panic is caught.
2022-12-28 16:54:42 +01:00
Chris Denton
874cefad9b
Powershell: Use WaitForExit
instead of -Wait
2022-12-28 15:41:46 +00:00
Mark Rousskov
fbe0450251
-Zrustdoc-scrape-examples no longer takes arguments
2022-12-28 09:20:57 -05:00
Lukas Markeffsky
9480314416
fix custom mir doc tests
2022-12-28 09:18:43 -05:00
Lukas Markeffsky
f4ff423d67
fix documenting private items of standard library
2022-12-28 09:18:43 -05:00
Lukas Markeffsky
fdf6cc34b2
delete more cfg(bootstrap)
2022-12-28 09:18:43 -05:00
Pietro Albini
11191279b7
Update bootstrap cfg
2022-12-28 09:18:43 -05:00
Pietro Albini
060a6ead83
bump stage0
2022-12-28 09:18:43 -05:00
Pietro Albini
f6762c2035
update stabilization version numbers
2022-12-28 09:18:42 -05:00
bors
266eef7701
Auto merge of #10119 - koka831:doc/config-default-value, r=xFrednet
...
fix codeblocks in the document
While I've looked into https://github.com/rust-lang/rust-clippy/issues/9990 , I found broken code blocks in the document.
This patch not only improves visibility, but also fixes a potential bug. When a lint description ends with code block, the string will have three backquotes at the end.
Since the current implementation prints the default value immediately after that, the markdown renderer is unable to properly close the code block.
e.g. `arithmetic_side_effects`, we can see code block is not rendered properly, and (I think) it's bit hard to understand what ``"defaults to `[]`"`` is meant.

In this PR, it will be rendered as:

changelog: none
r? `@xFrednet`
2022-12-28 13:53:34 +00:00
Matthias Krüger
d37cb3ff89
Rollup merge of #106199 - estebank:quiet-type-err-in-binding, r=compiler-errors
...
Silence knock-down errors on `[type error]` bindings
Fix #56036 , fix #76589 .
2022-12-28 14:40:03 +01:00
Matthias Krüger
08e2e4e4e4
Rollup merge of #106194 - notriddle:notriddle/sidebar-background, r=GuillaumeGomez
...
rustdoc: combine common sidebar background color CSS rules
2022-12-28 14:40:02 +01:00
Matthias Krüger
d07be1a304
Rollup merge of #106176 - compiler-errors:fn-kw-as-fn-trait, r=estebank
...
Recover `fn` keyword as `Fn` trait in bounds
`impl fn()` -> `impl Fn()`
Fixes #82515
2022-12-28 14:40:01 +01:00
Matthias Krüger
c991c243b7
Rollup merge of #106173 - compiler-errors:deduplicate-op-methods, r=jackh726
...
Deduplicate `op` methods
There are some operator-checking flavored methods in `FnCtxt` that can be deduplicated.
2022-12-28 14:40:01 +01:00
Matthias Krüger
31f5e753fb
Rollup merge of #106172 - estebank:suggest-impl-trait, r=compiler-errors
...
Suggest `impl Iterator` when possible for `_` return type
Address #106096 .
2022-12-28 14:40:00 +01:00
Matthias Krüger
f33ea418e2
Rollup merge of #106028 - Ezrashaw:add-docs+test-e0461, r=GuillaumeGomez
...
docs/test: add UI test and long-form error docs for `E0461`
Might take a couple of tries to pass CI. The UI test is x86-linux only; I'm not sure how to generalize it to other architectures.
r? ``@GuillaumeGomez``
2022-12-28 14:40:00 +01:00
bors
83a28ef095
Auto merge of #106129 - compiler-errors:compare_method-tweaks, r=BoxyUwU
...
Some `compare_method` tweaks
1. Make some of the comparison functions' names more regular
2. Reduce pub scope of some of the things in `compare_method`
~3. Remove some unnecessary opaque type handling code -- `InferCtxt` already is in a mode that doesn't define opaque types~
* moved to a different PR
4. Bubble up `ErrorGuaranteed` for region constraint errors in `compare_method` - Improves a redundant error message in one unit test.
5. Move the `compare_method` module to have a more general name, since it's more like `compare_impl_item` :)
6. Rename `collect_trait_impl_trait_tys`
2022-12-28 13:07:30 +00:00
bors
fba3d79df0
Auto merge of #2743 - RalfJung:path-join, r=RalfJung
...
simplify path joining code a bit
2022-12-28 11:45:18 +00:00
Ralf Jung
041ad1fcfe
simplify path joining code a bit
2022-12-28 12:44:41 +01:00
bors
6a20f7df57
Auto merge of #106209 - fee1-dead-contrib:rollup-47ysdcu, r=fee1-dead
...
Rollup of 9 pull requests
Successful merges:
- #94145 (Test leaking of BinaryHeap Drain iterators)
- #103945 (Remove `iter::Empty` hack)
- #104024 (Fix `unused_must_use` warning for `Box::from_raw`)
- #104708 (Fix backoff doc to match implementation)
- #105347 (Account for `match` expr in single line)
- #105484 (Implement allow-by-default `multiple_supertrait_upcastable` lint)
- #106184 (Fix `core::any` docs)
- #106201 (Emit fewer errors on invalid `#[repr(transparent)]` on `enum`)
- #106205 (Remove some totally duplicated files in `rustc_infer`)
Failed merges:
r? `@ghost`
`@rustbot` modify labels: rollup
2022-12-28 10:10:09 +00:00
bors
fbdf926e70
Auto merge of #2742 - RalfJung:targets, r=RalfJung
...
handle unknown targets more gracefully
In particular don't require a list of all OSes in the TLS machinery. Instead just fall back to doing nothing.
2022-12-28 09:51:40 +00:00
Ralf Jung
7bdb5da916
handle unknown targets more gracefully
2022-12-28 10:51:13 +01:00
Ralf Jung
b804c0d5a5
adjust message on non-unwinding panic
2022-12-28 10:38:04 +01:00
Deadbeef
983606d367
Allow trait method paths to satisfy const Fn bounds
2022-12-28 09:06:31 +00:00
fee1-dead
5e9c91c6dd
Rollup merge of #106205 - compiler-errors:oopsy, r=fee1-dead
...
Remove some totally duplicated files in `rustc_infer`
I have no idea why or how I duplicated these files from `compiler/rustc_infer/src/infer/error_reporting/note.rs`, but I did by accident, and nothing caught it 🤦
2022-12-28 15:51:43 +08:00
fee1-dead
f837da736f
Rollup merge of #106201 - estebank:verbose-transparent, r=compiler-errors
...
Emit fewer errors on invalid `#[repr(transparent)]` on `enum`
Fix #68420 .
2022-12-28 15:51:42 +08:00
fee1-dead
45d6f02ea5
Rollup merge of #106184 - albertlarsan68:docs-106154, r=Nilstrieb
...
Fix `core::any` docs
Thanks to ``@pbevin`` in #106154
Closes #106154
``@rustbot`` labels +A-docs
2022-12-28 15:51:42 +08:00
fee1-dead
8b3d0c4cf9
Rollup merge of #105484 - nbdd0121:upcast, r=compiler-errors
...
Implement allow-by-default `multiple_supertrait_upcastable` lint
The lint detects when an object-safe trait has multiple supertraits.
Enabled in libcore and liballoc as they are low-level enough that many embedded programs will use them.
r? `@nikomatsakis`
2022-12-28 15:51:41 +08:00
fee1-dead
ade9605a08
Rollup merge of #105347 - estebank:single-line-match, r=compiler-errors
...
Account for `match` expr in single line
When encountering `match Some(42) { Some(x) => x, None => "" };`, output
```
error[E0308]: `match` arms have incompatible types
--> f53.rs:2:52
|
2 | let _ = match Some(42) { Some(x) => x, None => "" };
| -------------- - ^^ expected integer, found `&str`
| | |
| | this is found to be of type `{integer}`
| `match` arms have incompatible types
```
2022-12-28 15:51:40 +08:00
fee1-dead
0818ba43a4
Rollup merge of #104708 - jonasspinner:fix-backoff-doc-to-match-implementation, r=compiler-errors
...
Fix backoff doc to match implementation
The commit 8dddb22943
in the crossbeam-channel PR (#93563 ) changed the backoff strategy to be quadratic instead of exponential. This updates the doc to prevent confusion.
2022-12-28 15:51:40 +08:00
fee1-dead
58233e90b8
Rollup merge of #104024 - noeddl:unused-must-use, r=compiler-errors
...
Fix `unused_must_use` warning for `Box::from_raw`
2022-12-28 15:51:39 +08:00
fee1-dead
d1193ad1e6
Rollup merge of #103945 - H4x5:remove-iter-empty-hack, r=compiler-errors
...
Remove `iter::Empty` hack
`iter::Empty` uses a newtype to work around `#![feature(const_fn_fn_ptr_basics)]`, which has been stable since 1.61.0.
2022-12-28 15:51:38 +08:00
fee1-dead
dc98aa681f
Rollup merge of #94145 - ssomers:binary_heap_tests, r=jyn514
...
Test leaking of BinaryHeap Drain iterators
Add test cases about forgetting the `BinaryHeap::Drain` iterator, and slightly fortifies some other test cases.
Consists of separate commits that I don't think are relevant on their own (but I'll happily turn these into more PRs if desired).
2022-12-28 15:51:37 +08:00
bors
9b889e53e7
Auto merge of #103881 - ChayimFriedman2:patch-2, r=compiler-errors
...
Clarify docs of `RefCell`
Comparison operators only panic if the `RefCell` is mutably borrowed, and `RefCell::swap()` can also panic if swapping a `RefCell` with itself.
2022-12-28 06:56:02 +00:00
Michael Goulet
605ad65f6a
Remove some totally duplicated files
2022-12-28 05:45:12 +00:00