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 E0102, E0412, E0413, E0415, E0416, E0419, E0423 and E0435 error explanation #27378

Merged
merged 13 commits into from
Aug 7, 2015

Conversation

GuillaumeGomez
Copy link
Member

Part of #24407.
r? @Manishearth

@GuillaumeGomez
Copy link
Member Author

I'm not sure at all this is enough to fully explain this error. Waiting for opinions.

@GuillaumeGomez GuillaumeGomez changed the title Add E0423 error explanation Add E0413 and E0423 error explanation Jul 29, 2015
// unit-like struct in scope
```

To fix this error, you have to change the declaration's name or the
Copy link
Member

Choose a reason for hiding this comment

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

you have to change the name of the declaration of shadowed object

@Manishearth
Copy link
Member

Leave out 424, the original error is wrong (it applies to both structs and struct variants, in positions other than function positions)



To fix this error, you have to change the name of the declaration of
shadowed object. Please also verify that neither name was misspelled.
Copy link
Contributor

Choose a reason for hiding this comment

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

s/shadowed object/the shadowed object/

@GuillaumeGomez GuillaumeGomez changed the title Add E0413 and E0423 error explanation Add E0413, E0423 and E0435 error explanation Jul 31, 2015
@GuillaumeGomez GuillaumeGomez changed the title Add E0413, E0423 and E0435 error explanation Add E0412, E0413, E0423 and E0435 error explanation Aug 4, 2015
@GuillaumeGomez GuillaumeGomez changed the title Add E0412, E0413, E0423 and E0435 error explanation Add E0102, E0412, E0413, E0423 and E0435 error explanation Aug 4, 2015
@GuillaumeGomez
Copy link
Member Author

Since #27491 has been merged. We can move forward on this PR.

@GuillaumeGomez GuillaumeGomez changed the title Add E0102, E0412, E0413, E0423 and E0435 error explanation Add E0102, E0412, E0413, E0419, E0423 and E0435 error explanation Aug 6, 2015
@GuillaumeGomez GuillaumeGomez changed the title Add E0102, E0412, E0413, E0419, E0423 and E0435 error explanation Add E0102, E0412, E0413, E0415, E0419, E0423 and E0435 error explanation Aug 6, 2015
@GuillaumeGomez GuillaumeGomez changed the title Add E0102, E0412, E0413, E0415, E0419, E0423 and E0435 error explanation Add E0102, E0412, E0413, E0415, E0416, E0419, E0423 and E0435 error explanation Aug 6, 2015
@@ -1118,6 +1118,36 @@ fn main() {
```
"##,

E0102: r##"
You hit this error because the compiler the compiler lacks information
Copy link
Member

Choose a reason for hiding this comment

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

the compiler is duplicated

"##,

E0423: r##"
A `struct` variant name was used like a function name. Example of
Copy link
Member

Choose a reason for hiding this comment

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

struct “variant”? Interestingly it was called so by yourself in c5f7c19. Stable and beta emit a better error message in this case.

Copy link
Member Author

Choose a reason for hiding this comment

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

So should I change it or not ?

Copy link
Member

Choose a reason for hiding this comment

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

I’m fine with merging this as it is currently and changing the explanation in the PR which updates the error message.

@@ -397,6 +397,102 @@ impl Bar {
```
"##,

E0412: r##"
An undeclared type name was used. Example of erroneous codes:
Copy link
Contributor

Choose a reason for hiding this comment

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

May want to say something about generics, e.g. fn foo(x: T) {} needing to be fn foo<T>(x: T) {}.

Copy link
Member Author

Choose a reason for hiding this comment

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

Done !

@brson
Copy link
Contributor

brson commented Aug 7, 2015

@bors r+

@bors
Copy link
Contributor

bors commented Aug 7, 2015

📌 Commit c3d147e has been approved by brson

@bors
Copy link
Contributor

bors commented Aug 7, 2015

⌛ Testing commit c3d147e with merge e5d90d9...

bors added a commit that referenced this pull request Aug 7, 2015
@bors
Copy link
Contributor

bors commented Aug 7, 2015

💔 Test failed - auto-linux-32-opt

@sfackler
Copy link
Member

sfackler commented Aug 7, 2015

@bors retry

@bors bors merged commit c3d147e into rust-lang:master Aug 7, 2015
@GuillaumeGomez GuillaumeGomez deleted the patch-2 branch August 7, 2015 21:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

9 participants