From c35e01e48e4eb6850f20628dde49f1204c2242c8 Mon Sep 17 00:00:00 2001 From: Orion Gonzalez Date: Tue, 27 Aug 2024 20:05:53 +0200 Subject: [PATCH] clarify what term can be --- compiler/rustc_parse/src/parser/item.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/compiler/rustc_parse/src/parser/item.rs b/compiler/rustc_parse/src/parser/item.rs index 8775d792c3d..7bdcac45455 100644 --- a/compiler/rustc_parse/src/parser/item.rs +++ b/compiler/rustc_parse/src/parser/item.rs @@ -49,7 +49,9 @@ fn parse_item_mod(&mut self, attrs: &mut AttrVec) -> PResult<'a, ItemInfo> { } /// Parses the contents of a module (inner attributes followed by module items). - /// We exit once we hit `term` + /// We exit once we hit `term` which can be either + /// - EOF (for files) + /// - `}` for mod items pub fn parse_mod( &mut self, term: &TokenKind,