Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add long error explanation for E0227 #92351

Merged
merged 1 commit into from
Dec 29, 2021
Merged

Add long error explanation for E0227 #92351

merged 1 commit into from
Dec 29, 2021

Conversation

TmLev
Copy link
Contributor

@TmLev TmLev commented Dec 28, 2021

Part of the #61137.

@rustbot rustbot added the T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. label Dec 28, 2021
@rust-highfive
Copy link
Collaborator

Some changes occurred in diagnostic error codes

cc @GuillaumeGomez

@rust-highfive
Copy link
Collaborator

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @petrochenkov (or someone else) soon.

Please see the contribution instructions for more information.

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Dec 28, 2021

To resolve this error, provide an explicit lifetime:

```rust
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: You don't need to add rust, it's the default. It's not a blocker for the PR though.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's nice to have syntax highlighting in vim while editing .md files.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Like I said, not a blocker. We generally don't add it but it's fine to have it here.

@@ -0,0 +1,33 @@
This error indicates that the compiler is unable to determine whether there is
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We try to provide a small description of the error first, and then provide more explanations after the erroneous code example. However in this case I'm not sure how to word it... If you have an idea, please go for it, otherwise I'll just approve as is.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, the only reason why I haven't included a small description is because I can't think of one.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Then it's fine. I'll approve the PR once the CI passed. Thanks for working on this!

@GuillaumeGomez
Copy link
Member

@bors: r+ rollup

@bors
Copy link
Contributor

bors commented Dec 28, 2021

📌 Commit 406d6d4 has been approved by GuillaumeGomez

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Dec 28, 2021
bors added a commit to rust-lang-ci/rust that referenced this pull request Dec 29, 2021
…askrgr

Rollup of 7 pull requests

Successful merges:

 - rust-lang#92075 (rustdoc: Only special case struct fields for intra-doc links, not enum variants)
 - rust-lang#92118 (Parse and suggest moving where clauses after equals for type aliases)
 - rust-lang#92237 (Visit expressions in-order when resolving pattern bindings)
 - rust-lang#92340 (rustdoc: Start cleaning up search index generation)
 - rust-lang#92351 (Add long error explanation for E0227)
 - rust-lang#92371 (Remove pretty printer space inside block with only outer attrs)
 - rust-lang#92372 (Print space after formal generic params in fn type)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit c82b2bc into rust-lang:master Dec 29, 2021
@rustbot rustbot added this to the 1.59.0 milestone Dec 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants