diff options
| author | Nika Layzell <nika@thelayzells.com> | 2022-06-17 22:10:07 -0400 |
|---|---|---|
| committer | Nika Layzell <nika@thelayzells.com> | 2022-06-17 22:10:07 -0400 |
| commit | df925fda9c9eee8010564dde7daa44bc5286446e (patch) | |
| tree | 8be972508319a7ee3c041e00e0979ae188047791 /compiler | |
| parent | af514240089891ddfaa3b9368dd255513141e7a9 (diff) | |
| download | rust-df925fda9c9eee8010564dde7daa44bc5286446e.tar.gz rust-df925fda9c9eee8010564dde7daa44bc5286446e.zip | |
review fixups
Diffstat (limited to 'compiler')
| -rw-r--r-- | compiler/rustc_expand/src/proc_macro_server.rs | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/compiler/rustc_expand/src/proc_macro_server.rs b/compiler/rustc_expand/src/proc_macro_server.rs index cc66eefac3e..af0b5639d61 100644 --- a/compiler/rustc_expand/src/proc_macro_server.rs +++ b/compiler/rustc_expand/src/proc_macro_server.rs @@ -498,12 +498,13 @@ impl server::TokenStream for Rustc<'_, '_> { } builder.build() } - fn into_iter( + fn into_trees( &mut self, stream: Self::TokenStream, ) -> Vec<TokenTree<Self::Group, Self::Punct, Self::Ident, Self::Literal>> { - // FIXME: This is a raw port of the previous approach, and can probably - // be optimized. + // FIXME: This is a raw port of the previous approach (which had a + // `TokenStreamIter` server-side object with a single `next` method), + // and can probably be optimized (for bulk conversion). let mut cursor = stream.into_trees(); let mut stack = Vec::new(); let mut tts = Vec::new(); |
