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

Remove Self: Sized from libsyntax::parse::lexer::Read::next_token() function #33506

Closed
gyscos opened this issue May 8, 2016 · 4 comments
Closed
Labels
E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.

Comments

@gyscos
Copy link

gyscos commented May 8, 2016

Commit 6887202 added the Self: Sized bound to the next_token function in the libsyntax::parse::lexer::Reader trait (diff here).
This bound doesn't seem necessary (it compiles fine without it), but it prevents using this method from a trait object.

Is there any reason for its addition? If not, could we remove it?

@mitaa
Copy link
Contributor

mitaa commented May 10, 2016

That must be a leftover from me trying to make unwrap_or_abort take a closure somehow work.. sorry.

#33199 (comment)

@Mark-Simulacrum Mark-Simulacrum added the E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue. label May 4, 2017
@Mark-Simulacrum
Copy link
Member

I'm marking this as E-easy because all that needs to be done is to remove Self: Sized from here, I believe.

@tommyip
Copy link
Contributor

tommyip commented May 4, 2017

I would like to take this issue.

@Mark-Simulacrum
Copy link
Member

Go ahead! Let us know what we can do to help you. You can reach out either here or on IRC (#rustc on irc.mozilla.org).

tommyip added a commit to tommyip/rust that referenced this issue May 4, 2017
The bound is not required for compiling but it prevents using `next_token()` from a trait object.

Fixes rust-lang#33506.
frewsxcv added a commit to frewsxcv/rust that referenced this issue May 5, 2017
Remove use of `Self: Sized` from libsyntax

The bound is not required for compiling but it prevents using `next_token()` from a trait object.

Fixes rust-lang#33506.
frewsxcv added a commit to frewsxcv/rust that referenced this issue May 5, 2017
Remove use of `Self: Sized` from libsyntax

The bound is not required for compiling but it prevents using `next_token()` from a trait object.

Fixes rust-lang#33506.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.
Projects
None yet
Development

No branches or pull requests

4 participants