summaryrefslogtreecommitdiffstats
path: root/src/column.rs
diff options
context:
space:
mode:
authorBenjamin Sago <ogham@bsago.me>2015-01-12 01:31:24 +0100
committerBenjamin Sago <ogham@bsago.me>2015-01-12 01:31:24 +0100
commit1c5409e253a34184f0fced80b488df61565e8f06 (patch)
tree1beed09d1896558477c56af7932aac3ba2fc7b88 /src/column.rs
parent2784baea0a18bf4ee2663b33751a90c17cc142be (diff)
Upgrade to Rust alpha
- uint -> usize - getopts Cargo library - replace feature gates with unstable APIs
Diffstat (limited to 'src/column.rs')
-rw-r--r--src/column.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/column.rs b/src/column.rs
index 5a4bdb0..4ef4f76 100644
--- a/src/column.rs
+++ b/src/column.rs
@@ -55,7 +55,7 @@ impl Column {
}
}
-fn spaces(length: uint) -> String {
+fn spaces(length: usize) -> String {
repeat(" ").take(length).collect()
}
@@ -65,7 +65,7 @@ fn spaces(length: uint) -> String {
// because these strings are usually full of control characters.
impl Alignment {
- pub fn pad_string(&self, string: &String, padding: uint) -> String {
+ pub fn pad_string(&self, string: &String, padding: usize) -> String {
match *self {
Alignment::Left => format!("{}{}", string, spaces(padding).as_slice()),
Alignment::Right => format!("{}{}", spaces(padding), string.as_slice()),