-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Add tests for expect ident but find enum or struct panic #22720
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 tests for expect ident but find enum or struct panic #22720
Conversation
r? @nick29581 (rust_highfive has picked a reviewer for you, use r? to override) |
enum_path.segments.len() == 1 && | ||
enum_path.segments[0].parameters.is_empty() | ||
{ | ||
// We expect an identifier, but duo to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit s/duo/due
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
r+ with the typo fixed. |
4ce608b
to
2931c21
Compare
When running
Should I expect this to only work for |
This is weird. This test in my local |
🙀 |
@bors: r- |
dammit bors |
I'm looking into it right now, could be some in between commits caused behavior change of the parser. And building LLVM, it will take a while. |
@Manishearth yeah, but I still need to verify it locally first. Besides I have the feeling that my patch will reduce to just bunch of tests 🚴 |
Closes rust-lang#22589 Closes rust-lang#22647 Closes rust-lang#22665 Closes rust-lang#22712
2931c21
to
a1396d2
Compare
It is merely tests now. r? @Manishearth |
@bors r=nick29581 rollup |
🙀 |
…-a-bar, r=nick29581 Closes rust-lang#22589 Closes rust-lang#22647 Closes rust-lang#22665 Closes rust-lang#22712
Not sure it's exactly the same, but crash Rust nightly from play.rust-lang.org as well: use std::rc::Rc;
fn main() {
match Rc::new(1) {
Rc<_> => {}
}
} |
@l0kod, playpen must've been a little bit lagged behind. Just run your code locally and use std::rc::Rc;
fn main() {
match Rc::new(1) {
Rc<_> => {} // error: unexpected token: `<`
}
} |
Closes #22589
Closes #22647
Closes #22665
Closes #22712