| Age | Commit message (Collapse) | Author | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This commit improves the calculation of code spans for intra-doc
resolution failures. All sugared doc comments should now have the
correct spans, including those where the comment is longer than the
docs.
It also fixes an issue where the spans were calculated incorrectly for
certain unsugared doc comments. The diagnostic will now always use the
span of the attributes, as originally intended.
Fixes #55964.
|
|
Add regression test for ICE
Fixes #55846 with a minimal (or as best as I can manage) test case. I tested this against 1.30.0 manually to confirm it crashes.
The issue seemed to have something to do with associated types. It's possible someone with more knowledge can shrink the test case down further, or make it clearer.
|
|
GuillaumeGomez:span-trait-method-invalid-nb-parameters, r=estebank
fix span for invalid number of parameters in trait method
Fixes #56582.
|
|
emit error with span for empty asserts
Fixes #55547.
|
|
|
|
|
|
|
|
Also, provide a suggestion for the correct syntax.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Encode `TraitAlias` as if they were `Trait`
Fix #56539.
|
|
|
|
Filter out `ProcMacroStub`s to avoid an ICE during cleaning.
Also add proc macros to `cache().paths` so it can generate links.
|
|
resolve: Reduce some clutter in import ambiguity errors
Noticed in https://www.reddit.com/r/rust/comments/a3pyrw/announcing_rust_131_and_rust_2018/eb8alhi/.
The first error is distracting, but unnecessary, it's a *consequence* of the ambiguity error and appears because one of the ambiguous `actix` modules (unsurprisingly) doesn't have the expected name in it.
|
|
Suggest an appropriate token when encountering `pub Ident<'a>`
Fix #55403. Follow up to #45997.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Use a function to access the Hir map to be able to turn it into a query later
r? @eddyb
|
|
Fix ICE with generators and NLL
Fix #55850.
This PR stops an ICE in #55850 by not panicking when a region cannot be named. However, this PR does not (yet) fix the underlying issue that the correct name for the test case provided for the issue (in this instance, `'a`) was not found.
This PR also lays a little bit of groundwork by categorizing yields separately from returns so that region naming can be specialized for this case.
r? @pnkfelix
|
|
codegen_utils, driver: fix clippy errors
- remove a superfluous conversion
- remove an explicit `return`
- rename `MetadataOnlyCodegenBackend::new` to `::boxed`
- single-arm `match` > `if let`
|
|
|
|
This commit puts a fix in place for the ICE in region naming code so
that it doesn't break the compiler. However, this results in the
diagnostic being poorer as the borrow explanation that was causing the
ICE is not being added - this should be fixed as a follow-up.
|
|
This commit emits a suggestion for adding an underscore binding to
arguments in trait methods that previously did not have a argument name
specified.
|
|
This commit adds a note providing context for the change to argument
names being required in the 2018 edition for trait methods.
|
|
Unsupport `#[derive(Trait)]` sugar for `#[derive_Trait]` legacy plugin attributes
This is a long deprecated unstable feature that doesn't mesh well with regular resolution/expansion.
How to fix broken code:
- The recommended way is to migrate to stable procedural macros - derives or attributes (https://doc.rust-lang.org/nightly/book/first-edition/procedural-macros.html).
- If that's not possible right now for some reason, you can keep code working with a simple mechanical replacement `#[derive(Legacy)]` -> `#[derive_Legacy]`.
Closes https://github.com/rust-lang/rust/issues/29644
r? @ghost
|
|
attributes
|
|
Ensure that Rustdoc discovers all necessary auto trait bounds
Fixes #50159
This commit makes several improvements to AutoTraitFinder:
* Call infcx.resolve_type_vars_if_possible before processing new
predicates. This ensures that we eliminate inference variables wherever
possible.
* Process all nested obligations we get from a vtable, not just ones
with depth=1.
* The 'depth=1' check was a hack to work around issues processing
certain predicates. The other changes in this commit allow us to
properly process all predicates that we encounter, so the check is no
longer necessary,
* Ensure that we only display predicates *without* inference variables
to the user, and only attempt to unify predicates that *have* an
inference variable as their type.
Additionally, the internal helper method is_of_param now operates
directly on a type, rather than taking a Substs. This allows us to use
the 'self_ty' method, rather than directly dealing with Substs.
|
|
|
|
Fix #56237: normalize type before deferred sizedness checking.
This seems to fix #56237, which was introduced by #56045. I don't thoroughly understand how this works, but the problem seemed to be a lack of normalization.
r? @cramertj
|
|
|