Skip to content

Fix E0118 #31347

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

Merged
merged 1 commit into from
Feb 3, 2016
Merged

Fix E0118 #31347

merged 1 commit into from
Feb 3, 2016

Conversation

GuillaumeGomez
Copy link
Member

r? @eddyb


```
impl SomeTypeThatDoesntExist { }
type NineString = &'static [char];
Copy link
Member

Choose a reason for hiding this comment

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

The type alias seems superfluous, and it's irrelevant to the error itself.

Copy link
Member Author

Choose a reason for hiding this comment

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

I'll also say that you can't implement a type which isn't defined in the current crate.

Copy link
Member

Choose a reason for hiding this comment

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

Type aliases don't change the situation at all, they're just confusing here since it seems like you're suggesting them as a solution even if they won't work.

@eddyb
Copy link
Member

eddyb commented Feb 1, 2016

cc @Manishearth

@GuillaumeGomez GuillaumeGomez force-pushed the fix_E0118 branch 4 times, most recently from 171f3c0 to 994ed2a Compare February 2, 2016 18:58
"no base type found for inherent implementation; \
implement a trait or new type instead");
"no base type found for inherent implementation; either \
implement a trait on it or create a newtype to wrap it \
Copy link
Member

Choose a reason for hiding this comment

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

the stuff after the semicolon should be in a help

"no base type found for inherent implementation; \
implement a trait or new type instead");
"no base type found for inherent implementation;");
span_help!(self.tcx.sess, item.span,
Copy link
Member

Choose a reason for hiding this comment

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

The two should be linked using struct_span_err.

@GuillaumeGomez
Copy link
Member Author

Updated.

@Manishearth
Copy link
Member

@bors r+

@bors
Copy link
Collaborator

bors commented Feb 2, 2016

📌 Commit db63a55 has been approved by Manishearth

Manishearth added a commit to Manishearth/rust that referenced this pull request Feb 2, 2016
bors added a commit that referenced this pull request Feb 3, 2016
@bors bors merged commit db63a55 into rust-lang:master Feb 3, 2016
@GuillaumeGomez GuillaumeGomez deleted the fix_E0118 branch February 3, 2016 07:51
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.

4 participants