chiark / gitweb /
jst-lower: Fix some output formatting
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 18 Jul 2021 23:01:16 +0000 (00:01 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Mon, 19 Jul 2021 01:12:09 +0000 (02:12 +0100)
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
jstest/jst-lower.rs

index 78909a7906d5cf2831ba1332fb1890add2be03ff..5462e4b6598291a356a4c57c3a75269fc1d538e2 100644 (file)
@@ -98,7 +98,7 @@ pub struct ZLevelShow<'z>(pub &'z ZLevel);
 impl Display for ZLevelShow<'_> {
   #[throws(fmt::Error)]
   fn fmt(&self, f: &mut Formatter) {
-    write!(f, "{:<20} {:6}", self.0.z.as_str(), self.0.zg)?;
+    write!(f, "{:<21} {:6}", self.0.z.as_str(), self.0.zg)?;
   }
 }
 #[ext(pub)]
@@ -159,7 +159,7 @@ impl Test {
     let new = sorted(&|p: &PieceCollated| p.new_z);
     for (o, n) in izip!(&old, &new).rev() {
       let pr = |p: &PieceCollated, zl: &ZLevel| {
-        print!("    {:5} {}{}{} {}",
+        print!("    {:6} {}{}{} {}",
                 p.id.to_string(),
                 if p.target  { "T" } else { "_" },
                 if p.heavy   { "H" } else { "_" },
@@ -328,7 +328,7 @@ impl TestsAccumulator {
 
     println!("-------------------- {} --------------------", name);
     for (id,p) in pieces.iter().rev() {
-      println!("    {:5} {}{}  {}",
+      println!("    {:6} {}{}  {}",
                 id.to_string(),
                 if targets.contains(id) { "T" } else { "_" },
                 if p.heavy()            { "H" } else { "_" },