Skip to content

Commit

Permalink
Merge pull request #282 from dtolnay/tokens
Browse files Browse the repository at this point in the history
Consistently use `tokens` as the name of the &mut TokenStream arg
  • Loading branch information
dtolnay authored Aug 22, 2024
2 parents a4a0abf + c77340a commit ba41109
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/to_tokens.rs
Original file line number Diff line number Diff line change
Expand Up @@ -189,14 +189,14 @@ impl ToTokens for Literal {
}

impl ToTokens for TokenTree {
fn to_tokens(&self, dst: &mut TokenStream) {
dst.append(self.clone());
fn to_tokens(&self, tokens: &mut TokenStream) {
tokens.append(self.clone());
}
}

impl ToTokens for TokenStream {
fn to_tokens(&self, dst: &mut TokenStream) {
dst.extend(iter::once(self.clone()));
fn to_tokens(&self, tokens: &mut TokenStream) {
tokens.extend(iter::once(self.clone()));
}

fn into_token_stream(self) -> TokenStream {
Expand Down

0 comments on commit ba41109

Please sign in to comment.