summaryrefslogtreecommitdiffstats
path: root/openpgp/src/message
diff options
context:
space:
mode:
authorNora Widdecke <nora@sequoia-pgp.org>2021-04-07 21:19:38 +0200
committerNora Widdecke <nora@sequoia-pgp.org>2021-04-09 13:13:59 +0200
commit253158696af836b4162fceadb29917f9eeb6d4a0 (patch)
treed2d7f8f43f4ab819832d322b3697fdf26604be41 /openpgp/src/message
parenta58579221bc8c4fbeba89bd55644415fe0368117 (diff)
Lint: Do not .clone a Copy type.
- https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
Diffstat (limited to 'openpgp/src/message')
-rw-r--r--openpgp/src/message/lexer.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/openpgp/src/message/lexer.rs b/openpgp/src/message/lexer.rs
index e1ac7194..8e6f8910 100644
--- a/openpgp/src/message/lexer.rs
+++ b/openpgp/src/message/lexer.rs
@@ -70,7 +70,7 @@ impl<'input> Iterator for Lexer<'input> {
type Item = LexerItem<Token, usize, LexicalError>;
fn next(&mut self) -> Option<Self::Item> {
- let n = self.iter.next().map(|(pos, tok)| (pos, tok.clone()));
+ let n = self.iter.next().map(|(pos, tok)| (pos, *tok));
if let Some((pos, tok)) = n {
Some(Ok((pos, tok, pos)))
} else {