about summary refs log tree commit diff
path: root/compiler/rustc_parse/src/parser/attr.rs
diff options
context:
space:
mode:
authorMatthias Krüger <matthias.krueger@famsik.de>2024-08-03 11:17:44 +0200
committerGitHub <noreply@github.com>2024-08-03 11:17:44 +0200
commitdee57ce043ffedd51ade01195829cead783a1a7e (patch)
tree3e3f427fafaf00e1bfc4329c04532a2f6779bd3d /compiler/rustc_parse/src/parser/attr.rs
parent2f549aac39612540332cd9b4b1b97680f3f6fc63 (diff)
parentd1f05fd1848fc68ed89d17f7937e358dacd8aed4 (diff)
downloadrust-dee57ce043ffedd51ade01195829cead783a1a7e.tar.gz
rust-dee57ce043ffedd51ade01195829cead783a1a7e.zip
Rollup merge of #128483 - nnethercote:still-more-cfg-cleanups, r=petrochenkov
Still more `cfg` cleanups

Found while looking closely at `cfg`/`cfg_attr` processing code.

r? `````````@petrochenkov`````````
Diffstat (limited to 'compiler/rustc_parse/src/parser/attr.rs')
-rw-r--r--compiler/rustc_parse/src/parser/attr.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/compiler/rustc_parse/src/parser/attr.rs b/compiler/rustc_parse/src/parser/attr.rs
index f34ef071e21..8fdfbcee385 100644
--- a/compiler/rustc_parse/src/parser/attr.rs
+++ b/compiler/rustc_parse/src/parser/attr.rs
@@ -8,7 +8,7 @@ use rustc_span::{sym, BytePos, Span};
 use thin_vec::ThinVec;
 use tracing::debug;
 
-use super::{AttrWrapper, Capturing, FnParseMode, ForceCollect, Parser, PathStyle};
+use super::{AttrWrapper, Capturing, FnParseMode, ForceCollect, Parser, ParserRange, PathStyle};
 use crate::{errors, fluent_generated as fluent, maybe_whole};
 
 // Public for rustfmt usage
@@ -313,8 +313,8 @@ impl<'a> Parser<'a> {
                 // inner attribute, for possible later processing in a `LazyAttrTokenStream`.
                 if let Capturing::Yes = self.capture_state.capturing {
                     let end_pos = self.num_bump_calls;
-                    let range = start_pos..end_pos;
-                    self.capture_state.inner_attr_ranges.insert(attr.id, range);
+                    let parser_range = ParserRange(start_pos..end_pos);
+                    self.capture_state.inner_attr_parser_ranges.insert(attr.id, parser_range);
                 }
                 attrs.push(attr);
             } else {