tangled
alpha
login
or
join now
tgirl.cloud
/
lix-diff
0
fork
atom
this repo has no description
0
fork
atom
overview
issues
pulls
pipelines
refactor: make version list display less cursed
isabelroses.com
10 months ago
60d8fac0
7d9ae9fc
+6
-7
1 changed file
expand all
collapse all
unified
split
src
versioning.rs
+6
-7
src/versioning.rs
···
63
64
impl Display for VersionList {
65
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
66
-
let mut out = String::new();
67
-
for version in &self.0 {
68
-
out.push_str(&version.to_string());
69
-
out.push_str(", ");
70
-
}
71
-
out.pop(); // remove last comma
72
-
out.pop(); // remove last space
73
write!(f, "{out}")
74
}
75
}
···
63
64
impl Display for VersionList {
65
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
66
+
let out = self
67
+
.0
68
+
.iter()
69
+
.map(ToString::to_string)
70
+
.collect::<Vec<_>>()
71
+
.join(", ");
0
72
write!(f, "{out}")
73
}
74
}