Skip to content

Flood of unexpected token: <eof> errors triggered by foo(|_|) #32505

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

Closed
0x7CFE opened this issue Mar 26, 2016 · 4 comments
Closed

Flood of unexpected token: <eof> errors triggered by foo(|_|) #32505

0x7CFE opened this issue Mar 26, 2016 · 4 comments
Assignees
Labels
A-diagnostics Area: Messages for errors, warnings, and lints E-needs-test Call for participation: An issue has been fixed and does not reproduce, but no test has been added. P-low Low priority regression-from-stable-to-nightly Performance or correctness regression from stable to nightly.

Comments

@0x7CFE
Copy link

0x7CFE commented Mar 26, 2016

The easiest way to reproduce the error is to compile the following code:

pub fn test() {
    foo(|_|)
}

After I try rustc report.rs -o test I get the following output:

report.rs:3:1: 3:2 error: unexpected token: `<eof>`
report.rs:3 }
            ^
report.rs:3:1: 3:2 error: unexpected token: `<eof>`
report.rs:3 }
            ^
report.rs:3:1: 3:2 error: unexpected token: `<eof>`
report.rs:3 }
            ^
(ad infinitum...)

I expect to get the single line error output, not the flood.

Meta

rustc 1.9.0-dev (10bdd80 2016-03-18)
binary: rustc
commit-hash: 10bdd80
commit-date: 2016-03-18
host: x86_64-unknown-linux-gnu
release: 1.9.0-dev

@0x7CFE 0x7CFE changed the title Flood of unexpected token: <eof> errors in compiler output Flood of unexpected token: <eof> errors triggered by foo(|_|) Mar 26, 2016
@0x7CFE
Copy link
Author

0x7CFE commented Mar 26, 2016

Looks like it is a fairly recent bug. It reproduces on the nightly build, yet version (rustc 1.7.0-beta.4 (5ed7d4e31 2016-02-26)) works ok.

I checked on my machine and through versions available at http://rust.godbolt.org/

@nagisa nagisa added A-diagnostics Area: Messages for errors, warnings, and lints regression-from-stable-to-nightly Performance or correctness regression from stable to nightly. labels Mar 26, 2016
@nagisa
Copy link
Member

nagisa commented Mar 26, 2016

#32479 might help.

@eddyb
Copy link
Member

eddyb commented Mar 26, 2016

@nagisa It's actually fixed on master.

@eddyb eddyb added the E-needs-test Call for participation: An issue has been fixed and does not reproduce, but no test has been added. label Mar 26, 2016
@nikomatsakis
Copy link
Contributor

triage: P-low

@rust-highfive rust-highfive added the P-low Low priority label Apr 7, 2016
nikomatsakis added a commit to nikomatsakis/rust that referenced this issue Apr 7, 2016
@nikomatsakis nikomatsakis self-assigned this Apr 7, 2016
Manishearth added a commit to Manishearth/rust that referenced this issue Apr 8, 2016
Manishearth added a commit to Manishearth/rust that referenced this issue Apr 10, 2016
steveklabnik added a commit to steveklabnik/rust that referenced this issue Apr 11, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-diagnostics Area: Messages for errors, warnings, and lints E-needs-test Call for participation: An issue has been fixed and does not reproduce, but no test has been added. P-low Low priority regression-from-stable-to-nightly Performance or correctness regression from stable to nightly.
Projects
None yet
Development

No branches or pull requests

5 participants