| Age | Commit message (Collapse) | Author | Lines |
|
see #106182
|
|
|
|
|
|
|
|
|
|
The test was minified from the published `msf-ice:0.2.1` crate which failed in a crater run.
A faulty compiler was triggering a `higher-ranked lifetime error`:
> could not prove `[async block@...]: Send`
|
|
r=notriddle
Migrate more scraped examples CSS rules to CSS variables
It's based on https://github.com/rust-lang/rust/pull/106218 so it will need to wait for it to be merged first.
r? `@notriddle`
|
|
r=compiler-errors
Allow trait method paths to satisfy const Fn bounds
r? `@oli-obk`
|
|
Rollup of 9 pull requests
Successful merges:
- #104531 (Provide a better error and a suggestion for `Fn` traits with lifetime params)
- #105899 (`./x doc library --open` opens `std`)
- #106190 (Account for multiple multiline spans with empty padding)
- #106202 (Trim more paths in obligation types)
- #106234 (rustdoc: simplify settings, help, and copy button CSS by not reusing)
- #106236 (docs/test: add docs and a UI test for `E0514` and `E0519`)
- #106259 (Update Clippy)
- #106260 (Fix index out of bounds issues in rustdoc)
- #106263 (Formatter should not try to format non-Rust files)
Failed merges:
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
Monomorphise `#[repr(transparent)]` parameterized ADTs before turning
them into an Itanium mangled String.
`#[repr(transparent)]` ADTs currently use the single field to represent
them in their CFI type ID to ensure that they are compatible. However,
if that type involves a type parameter instantiated at the ADT level, as
in `ManuallyDrop`, this will currently ICE as the `Parameter` type
cannot be mangled. Since this happens at lowering time, it should always
be concrete after substitution.
Fixes #106230
|
|
|
|
Fix index out of bounds issues in rustdoc
Fixes #106213
r? `@matthiaskrgr`
|
|
docs/test: add docs and a UI test for `E0514` and `E0519`
No UI test on `E0514`, it would need to compile with a different `rustc` version.
r? `@GuillaumeGomez`
|
|
Trim more paths in obligation types
|
|
Account for multiple multiline spans with empty padding
Instead of
```
LL | fn oom(
| __^
| | _|
| ||
LL | || ) {
| ||_-
LL | | }
| |__^
```
emit
```
LL | // fn oom(
LL | || ) {
| ||_-
LL | | }
| |__^
```
|
|
r=estebank
Provide a better error and a suggestion for `Fn` traits with lifetime params
Given `Fn`-family traits with lifetime params in trait bounds like `fn f(_: impl Fn<'a>(&'a str) -> bool)`, we currently produce many unhelpful errors.
This PR allows these situations to suggest simply using Higher-Rank Trait Bounds like `for<'a> Fn(&'a str) -> bool`.
Fixes https://github.com/rust-lang/rust/issues/103490.
|
|
Instead of
```
LL | fn oom(
| __^
| | _|
| ||
LL | || ) {
| ||_-
LL | | }
| |__^
```
emit
```
LL | // fn oom(
LL | || ) {
| ||_-
LL | | }
| |__^
```
|
|
Rollup of 9 pull requests
Successful merges:
- #106208 (Make trait/impl `where` clause mismatch on region error a bit more actionable)
- #106216 (Powershell: Use `WaitForExit` instead of `-Wait`)
- #106217 (rustdoc: remove unnecessary `.tooltip::after { text-align: center }`)
- #106218 (Migrate css var scraped examples)
- #106221 (Rename `Rptr` to `Ref` in AST and HIR)
- #106223 (On unsized locals with explicit types suggest `&`)
- #106225 (Remove CraftSpider from review rotation)
- #106229 (update Miri)
- #106242 (Detect diff markers in the parser)
Failed merges:
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
|
|
Detect diff markers in the parser
Partly address #32059.
|
|
On unsized locals with explicit types suggest `&`
Fix #72742.
|
|
r=compiler-errors
Rename `Rptr` to `Ref` in AST and HIR
The name makes a lot more sense, and `ty::TyKind` calls it `Ref` already as well.
|
|
r=notriddle
Migrate css var scraped examples
r? ``@notriddle``
|
|
rustdoc: remove unnecessary `.tooltip::after { text-align: center }`
This doesn't have an effect, since these tooltip are only one line anyway.
|
|
Make trait/impl `where` clause mismatch on region error a bit more actionable
Improve `where` clause suggestions for GATs/methods that have incompatible region predicates in their `where` clauses.
Also addresses this diagnostic that went away https://github.com/rust-lang/rust/pull/106129#discussion_r1056875772
|
|
Nilstrieb:no-more-being-clueless-whether-it-really-is-a-literal, r=compiler-errors
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.
Fixes #106191
|
|
|
|
This reverts commit b656e2413022de1863b9ea8db87454477b816042.
|
|
Give the correct track-caller location with MIR inlining.
Fixes https://github.com/rust-lang/rust/issues/105538
|
|
Currently, given `Fn`-family traits with lifetime params like
`Fn<'a>(&'a str) -> bool`, many unhelpful errors show up. These are a
bit confusing.
This commit allows these situations to suggest simply using
higher-ranked trait bounds like `for<'a> Fn(&'a str) -> bool`.
|
|
|
|
|
|
|
|
|
|
Partly address #32059.
|
|
|
|
Properly calculate best failure in macro matching
Previously, we used spans. This was not good. Sometimes, the span of the token that failed to match may come from a position later in the file which has been transcribed into a token stream way earlier in the file. If precisely this token fails to match, we think that it was the best match because its span is so high, even though other arms might have gotten further in the token stream.
We now try to properly use the location in the token stream.
This needs a little cleanup as the `best_failure` field is getting out of hand but it should be mostly good to go. I hope I didn't violate too many abstraction boundaries..
|
|
Fix #72742.
|
|
|
|
|
|
The name makes a lot more sense, and `ty::TyKind` calls it `Ref` already
as well.
|
|
This doesn't have an effect, since these tooltip are only one line anyway.
|
|
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
|
|
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.
|
|
|
|
Silence knock-down errors on `[type error]` bindings
Fix #56036, fix #76589.
|
|
r=GuillaumeGomez
rustdoc: combine common sidebar background color CSS rules
|
|
Recover `fn` keyword as `Fn` trait in bounds
`impl fn()` -> `impl Fn()`
Fixes #82515
|
|
Suggest `impl Iterator` when possible for `_` return type
Address #106096.
|
|
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`
|