summaryrefslogtreecommitdiffstats
path: root/src/format.rs
diff options
context:
space:
mode:
authorPierre-Henri Symoneaux <pierre.henri.symoneaux@gmail.com>2019-08-25 20:19:20 +0200
committerPierre-Henri Symoneaux <pierre.henri.symoneaux@gmail.com>2019-08-25 20:19:20 +0200
commit2040ec8190518db84d1651c596950488750ab567 (patch)
treed318f6a8e2b59c5c208f62c92ad9d9cd65d28d3a /src/format.rs
parentcb6a033d7a212674c356c1a8365511abe2b4fca9 (diff)
Fixed a few clippy warnings (but not all)
Diffstat (limited to 'src/format.rs')
-rw-r--r--src/format.rs10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/format.rs b/src/format.rs
index ddf6713..9339348 100644
--- a/src/format.rs
+++ b/src/format.rs
@@ -60,10 +60,10 @@ impl LineSeparator {
/// and `junc` is the one used for junctions between columns and lines
pub fn new(line: char, junc: char, ljunc: char, rjunc: char) -> LineSeparator {
LineSeparator {
- line: line,
- junc: junc,
- ljunc: ljunc,
- rjunc: rjunc,
+ line,
+ junc,
+ ljunc,
+ rjunc,
}
}
@@ -80,7 +80,7 @@ impl LineSeparator {
if lborder {
out.write_all(Utf8Char::from(self.ljunc).as_bytes())?;
}
- let mut iter = col_width.into_iter().peekable();
+ let mut iter = col_width.iter().peekable();
while let Some(width) = iter.next() {
for _ in 0..width + padding.0 + padding.1 {
out.write_all(Utf8Char::from(self.line).as_bytes())?;