about summary refs log tree commit diff
path: root/src/test/run-make/unicode-input
diff options
context:
space:
mode:
authorAlex Crichton <alex@alexcrichton.com>2015-01-01 23:53:35 -0800
committerAlex Crichton <alex@alexcrichton.com>2015-01-03 23:43:57 -0800
commit7d8d06f86b48520814596bd5363d2b82bc619774 (patch)
treeeda093ca208286fd8679da8de9f3597b7a024c50 /src/test/run-make/unicode-input
parent470118f3e915cdc8f936aca0640b28a7a3d8dc6c (diff)
downloadrust-7d8d06f86b48520814596bd5363d2b82bc619774.tar.gz
rust-7d8d06f86b48520814596bd5363d2b82bc619774.zip
Remove deprecated functionality
This removes a large array of deprecated functionality, regardless of how
recently it was deprecated. The purpose of this commit is to clean out the
standard libraries and compiler for the upcoming alpha release.

Some notable compiler changes were to enable warnings for all now-deprecated
command line arguments (previously the deprecated versions were silently
accepted) as well as removing deriving(Zero) entirely (the trait was removed).

The distribution no longer contains the libtime or libregex_macros crates. Both
of these have been deprecated for some time and are available externally.
Diffstat (limited to 'src/test/run-make/unicode-input')
-rw-r--r--src/test/run-make/unicode-input/span_length.rs6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/test/run-make/unicode-input/span_length.rs b/src/test/run-make/unicode-input/span_length.rs
index f83734b1502..ae638399450 100644
--- a/src/test/run-make/unicode-input/span_length.rs
+++ b/src/test/run-make/unicode-input/span_length.rs
@@ -8,9 +8,10 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-use std::{char, os};
 use std::io::{File, Command};
+use std::iter::repeat;
 use std::rand::{thread_rng, Rng};
+use std::{char, os};
 
 // creates a file with `fn main() { <random ident> }` and checks the
 // compiler emits a span of the appropriate length (for the
@@ -60,7 +61,8 @@ fn main() {
         let err = String::from_utf8_lossy(result.error.as_slice());
 
         // the span should end the line (e.g no extra ~'s)
-        let expected_span = format!("^{}\n", "~".repeat(n - 1));
+        let expected_span = format!("^{}\n", repeat("~").take(n - 1)
+                                                        .collect::<String>());
         assert!(err.as_slice().contains(expected_span.as_slice()));
     }
 }