mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-11-23 13:13:34 +00:00
commit
404dd8245e
3 changed files with 11 additions and 1 deletions
|
@ -284,7 +284,6 @@ fn check_tts<'a>(cx: &EarlyContext<'a>, tts: &ThinTokenStream, is_write: bool) -
|
|||
let mut idx = 0;
|
||||
loop {
|
||||
if !parser.eat(&token::Comma) {
|
||||
assert!(parser.eat(&token::Eof));
|
||||
return (Some(fmtstr), expr);
|
||||
}
|
||||
let token_expr = match parser.parse_expr().map_err(|mut err| err.cancel()) {
|
||||
|
|
3
tests/ui/issue-3145.rs
Normal file
3
tests/ui/issue-3145.rs
Normal file
|
@ -0,0 +1,3 @@
|
|||
fn main() {
|
||||
println!("{}" a); //~ERROR expected token: `,`
|
||||
}
|
8
tests/ui/issue-3145.stderr
Normal file
8
tests/ui/issue-3145.stderr
Normal file
|
@ -0,0 +1,8 @@
|
|||
error: expected token: `,`
|
||||
--> $DIR/issue-3145.rs:2:19
|
||||
|
|
||||
2 | println!("{}" a); //~ERROR expected token: `,`
|
||||
| ^
|
||||
|
||||
error: aborting due to previous error
|
||||
|
Loading…
Reference in a new issue