diff options
| author | Simon Sapin <simon.sapin@exyr.org> | 2013-12-23 17:45:01 +0100 |
|---|---|---|
| committer | Simon Sapin <simon.sapin@exyr.org> | 2014-01-21 15:48:48 -0800 |
| commit | 05ae134acebee3f35af4880de113a7ae7ce20002 (patch) | |
| tree | 096daf1c7c42bd04ac3d1f11f710fd9786d9937a /src/compiletest | |
| parent | b8c41492939c77b7139e46ee67375b47041f6692 (diff) | |
[std::str] Rename from_utf8_owned_opt() to from_utf8_owned(), drop the old from_utf8_owned() behavior
Diffstat (limited to 'src/compiletest')
| -rw-r--r-- | src/compiletest/procsrv.rs | 4 | ||||
| -rw-r--r-- | src/compiletest/runtest.rs | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/compiletest/procsrv.rs b/src/compiletest/procsrv.rs index f919274f2ed..83fb267b0e7 100644 --- a/src/compiletest/procsrv.rs +++ b/src/compiletest/procsrv.rs @@ -66,8 +66,8 @@ pub fn run(lib_path: &str, Some(Result { status: status, - out: str::from_utf8_owned(output), - err: str::from_utf8_owned(error) + out: str::from_utf8_owned(output).unwrap(), + err: str::from_utf8_owned(error).unwrap() }) }, None => None diff --git a/src/compiletest/runtest.rs b/src/compiletest/runtest.rs index 7fede7f855d..1d8e5a707ed 100644 --- a/src/compiletest/runtest.rs +++ b/src/compiletest/runtest.rs @@ -154,7 +154,7 @@ fn run_pretty_test(config: &config, props: &TestProps, testfile: &Path) { match props.pp_exact { Some(_) => 1, None => 2 }; let src = File::open(testfile).read_to_end(); - let src = str::from_utf8_owned(src); + let src = str::from_utf8_owned(src).unwrap(); let mut srcs = ~[src]; let mut round = 0; @@ -176,7 +176,7 @@ fn run_pretty_test(config: &config, props: &TestProps, testfile: &Path) { Some(ref file) => { let filepath = testfile.dir_path().join(file); let s = File::open(&filepath).read_to_end(); - str::from_utf8_owned(s) + str::from_utf8_owned(s).unwrap() } None => { srcs[srcs.len() - 2u].clone() } }; @@ -1100,7 +1100,7 @@ fn disassemble_extract(config: &config, _props: &TestProps, fn count_extracted_lines(p: &Path) -> uint { let x = File::open(&p.with_extension("ll")).read_to_end(); - let x = str::from_utf8_owned(x); + let x = str::from_utf8_owned(x).unwrap(); x.lines().len() } |
