about summary refs log tree commit diff
path: root/compiler/rustc_attr_parsing/src/parser.rs
diff options
context:
space:
mode:
authorNicholas Nethercote <n.nethercote@gmail.com>2024-04-18 16:22:02 +1000
committerNicholas Nethercote <n.nethercote@gmail.com>2025-02-28 08:42:06 +1100
commit7ea59e053bed52249ba8f42cbdbc7301312197e3 (patch)
treea7552e6e474d5f21e2a57e7b61938e4618e55a0a /compiler/rustc_attr_parsing/src/parser.rs
parentef1114a964bcb15ba5c60551f925d287eb153bb9 (diff)
downloadrust-7ea59e053bed52249ba8f42cbdbc7301312197e3.tar.gz
rust-7ea59e053bed52249ba8f42cbdbc7301312197e3.zip
Remove `NtMeta`.
Note: there was an existing code path involving `Interpolated` in
`MetaItem::from_tokens` that was dead. This commit transfers that to the
new form, but puts an `unreachable!` call inside it.
Diffstat (limited to 'compiler/rustc_attr_parsing/src/parser.rs')
-rw-r--r--compiler/rustc_attr_parsing/src/parser.rs9
1 files changed, 0 insertions, 9 deletions
diff --git a/compiler/rustc_attr_parsing/src/parser.rs b/compiler/rustc_attr_parsing/src/parser.rs
index b6d66af4466..2604188bca2 100644
--- a/compiler/rustc_attr_parsing/src/parser.rs
+++ b/compiler/rustc_attr_parsing/src/parser.rs
@@ -481,15 +481,6 @@ impl<'a> MetaItemListParserContext<'a> {
                 self.inside_delimiters.peek()
             {
                 match &**nt {
-                    // or maybe a full nt meta including the path but we return immediately
-                    token::Nonterminal::NtMeta(item) => {
-                        self.inside_delimiters.next();
-
-                        return Some(MetaItemOrLitParser::MetaItemParser(MetaItemParser {
-                            path: PathParser::Ast(&item.path),
-                            args: ArgParser::from_attr_args(&item.args, self.dcx),
-                        }));
-                    }
                     // an already interpolated path from a macro expansion is a path, no need to parse
                     // one from tokens
                     token::Nonterminal::NtPath(path) => {