-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Closed
Labels
A-parserArea: The lexing & parsing of Rust source code to an ASTArea: The lexing & parsing of Rust source code to an AST
Description
Haven't confirmed if it has been fixed since 02/22
pub fn f<F: FnOnce(u64) -> u64>(f1: F) -> u64 {
f1(1)
}
#[test]
fn test_weird_rustc_thing() {
let y = f({
|x| x+1
); // shouldn't this need a closing curly brace?
assert_eq!(y, 2);
println!("WEIRD RUSTC BUG");
}
Seems to only repro inside an inner mod.
Here's a link to a repro
https://github.com/nipunn1313/rustc_parser_bug
Metadata
Metadata
Assignees
Labels
A-parserArea: The lexing & parsing of Rust source code to an ASTArea: The lexing & parsing of Rust source code to an AST