about summary refs log tree commit diff
path: root/compiler/rustc_parse/src/parser/mod.rs
diff options
context:
space:
mode:
authorNicholas Nethercote <n.nethercote@gmail.com>2022-09-09 17:15:53 +1000
committerNicholas Nethercote <n.nethercote@gmail.com>2022-09-09 17:25:38 +1000
commitd2df07c425f9b390c33e0ac31674ce4794352b3a (patch)
treeb8e36ff352f2ca9a6ae20f65cfc6d648d1857942 /compiler/rustc_parse/src/parser/mod.rs
parentf6c9e1df5937a8f4dad6739368e4eb5ed453dddd (diff)
downloadrust-d2df07c425f9b390c33e0ac31674ce4794352b3a.tar.gz
rust-d2df07c425f9b390c33e0ac31674ce4794352b3a.zip
Rename `{Create,Lazy}TokenStream` as `{To,Lazy}AttrTokenStream`.
`To` is better than `Create` for indicating that this is a non-consuming
conversion, rather than creating something out of nothing.

And the addition of `Attr` is because the current names makes them sound
like they relate to `TokenStream`, but really they relate to
`AttrTokenStream`.
Diffstat (limited to 'compiler/rustc_parse/src/parser/mod.rs')
-rw-r--r--compiler/rustc_parse/src/parser/mod.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/rustc_parse/src/parser/mod.rs b/compiler/rustc_parse/src/parser/mod.rs
index af8f55832a2..4cb198561e0 100644
--- a/compiler/rustc_parse/src/parser/mod.rs
+++ b/compiler/rustc_parse/src/parser/mod.rs
@@ -237,7 +237,7 @@ struct TokenCursor {
     // the trailing `>>` token. The `break_last_token`
     // field is used to track this token - it gets
     // appended to the captured stream when
-    // we evaluate a `LazyTokenStream`
+    // we evaluate a `LazyAttrTokenStream`.
     break_last_token: bool,
 }
 
@@ -1465,7 +1465,7 @@ pub fn emit_unclosed_delims(unclosed_delims: &mut Vec<UnmatchedBrace>, sess: &Pa
 }
 
 /// A helper struct used when building an `AttrTokenStream` from
-/// a `LazyTokenStream`. Both delimiter and non-delimited tokens
+/// a `LazyAttrTokenStream`. Both delimiter and non-delimited tokens
 /// are stored as `FlatToken::Token`. A vector of `FlatToken`s
 /// is then 'parsed' to build up an `AttrTokenStream` with nested
 /// `AttrTokenTree::Delimited` tokens.