about summary refs log tree commit diff
path: root/compiler/rustc_parse/src/parser/generics.rs
diff options
context:
space:
mode:
authorNicholas Nethercote <n.nethercote@gmail.com>2024-01-05 10:55:45 +1100
committerNicholas Nethercote <n.nethercote@gmail.com>2024-01-08 16:03:41 +1100
commit1b6c8e7533ae387ed320fc55a45dee95acc311ee (patch)
treed9fe7650f6006cf7068e969b3eac8389c0245183 /compiler/rustc_parse/src/parser/generics.rs
parent3ce34f42e160d7e63132c7e3994861bb876eb943 (diff)
downloadrust-1b6c8e7533ae387ed320fc55a45dee95acc311ee.tar.gz
rust-1b6c8e7533ae387ed320fc55a45dee95acc311ee.zip
Remove a third `DiagnosticBuilder::emit_without_consuming` call.
It's not clear why this was here, because the created error is returned
as a normal error anyway.

Nor is it clear why removing the call works. The change doesn't affect
any tests; `tests/ui/parser/issues/issue-102182-impl-trait-recover.rs`
looks like the only test that could have been affected.
Diffstat (limited to 'compiler/rustc_parse/src/parser/generics.rs')
-rw-r--r--compiler/rustc_parse/src/parser/generics.rs1
1 files changed, 0 insertions, 1 deletions
diff --git a/compiler/rustc_parse/src/parser/generics.rs b/compiler/rustc_parse/src/parser/generics.rs
index 7ff72eb5fb3..66aa8cbcda4 100644
--- a/compiler/rustc_parse/src/parser/generics.rs
+++ b/compiler/rustc_parse/src/parser/generics.rs
@@ -77,7 +77,6 @@ impl<'a> Parser<'a> {
                                     Applicability::MachineApplicable,
                                 );
                             }
-                            err.emit_without_consuming();
                             return Err(err);
                         }
                     }