Skip to content

Commit 9908eb9

Browse files
committed
---
yaml --- r: 195310 b: refs/heads/snap-stage3 c: e604382 h: refs/heads/master v: v3
1 parent b7c1db0 commit 9908eb9

File tree

1,625 files changed

+8449
-8102
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,625 files changed

+8449
-8102
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
refs/heads/master: 14192d6df5cc714e5c9a3ca70b08f2514d977be2
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
4-
refs/heads/snap-stage3: 5299d36c52c71d22031f2c0ea4badee412ea6861
4+
refs/heads/snap-stage3: e604382ad230219f0f692188a6802fd046574444
55
refs/heads/try: 961e0358e1a5c0faaef606e31e9965742c1643bf
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/dist-snap: ba4081a5a8573875fed17545846f6f6902c8ba8d

branches/snap-stage3/src/compiletest/compiletest.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,9 @@
1212

1313
#![feature(box_syntax)]
1414
#![feature(collections)]
15+
#![feature(int_uint)]
1516
#![feature(old_io)]
17+
#![feature(old_path)]
1618
#![feature(rustc_private)]
1719
#![feature(unboxed_closures)]
1820
#![feature(std_misc)]

branches/snap-stage3/src/compiletest/errors.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,13 @@ use std::io::prelude::*;
1515
use std::path::Path;
1616

1717
pub struct ExpectedError {
18-
pub line: usize,
18+
pub line: uint,
1919
pub kind: String,
2020
pub msg: String,
2121
}
2222

2323
#[derive(PartialEq, Debug)]
24-
enum WhichLine { ThisLine, FollowPrevious(usize), AdjustBackward(usize) }
24+
enum WhichLine { ThisLine, FollowPrevious(uint), AdjustBackward(uint) }
2525

2626
/// Looks for either "//~| KIND MESSAGE" or "//~^^... KIND MESSAGE"
2727
/// The former is a "follow" that inherits its target from the preceding line;
@@ -58,8 +58,8 @@ pub fn load_errors(testfile: &Path) -> Vec<ExpectedError> {
5858
}).collect()
5959
}
6060

61-
fn parse_expected(last_nonfollow_error: Option<usize>,
62-
line_num: usize,
61+
fn parse_expected(last_nonfollow_error: Option<uint>,
62+
line_num: uint,
6363
line: &str) -> Option<(WhichLine, ExpectedError)> {
6464
let start = match line.find("//~") { Some(i) => i, None => return None };
6565
let (follow, adjusts) = if line.char_at(start + 3) == '|' {

branches/snap-stage3/src/compiletest/header.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -357,7 +357,7 @@ pub fn parse_name_value_directive(line: &str, directive: &str)
357357
}
358358
}
359359

360-
pub fn gdb_version_to_int(version_string: &str) -> isize {
360+
pub fn gdb_version_to_int(version_string: &str) -> int {
361361
let error_string = format!(
362362
"Encountered GDB version string with unexpected format: {}",
363363
version_string);
@@ -369,17 +369,17 @@ pub fn gdb_version_to_int(version_string: &str) -> isize {
369369
panic!("{}", error_string);
370370
}
371371

372-
let major: isize = components[0].parse().ok().expect(&error_string);
373-
let minor: isize = components[1].parse().ok().expect(&error_string);
372+
let major: int = components[0].parse().ok().expect(&error_string);
373+
let minor: int = components[1].parse().ok().expect(&error_string);
374374

375375
return major * 1000 + minor;
376376
}
377377

378-
pub fn lldb_version_to_int(version_string: &str) -> isize {
378+
pub fn lldb_version_to_int(version_string: &str) -> int {
379379
let error_string = format!(
380380
"Encountered LLDB version string with unexpected format: {}",
381381
version_string);
382382
let error_string = error_string;
383-
let major: isize = version_string.parse().ok().expect(&error_string);
383+
let major: int = version_string.parse().ok().expect(&error_string);
384384
return major;
385385
}

branches/snap-stage3/src/compiletest/procsrv.rs

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,25 +8,27 @@
88
// option. This file may not be copied, modified, or distributed
99
// except according to those terms.
1010

11+
#![allow(deprecated)] // for old path, for dynamic_lib
12+
1113
use std::dynamic_lib::DynamicLibrary;
1214
use std::io::prelude::*;
13-
use std::path::PathBuf;
15+
use std::old_path::Path;
1416
use std::process::{ExitStatus, Command, Child, Output, Stdio};
1517

1618
fn add_target_env(cmd: &mut Command, lib_path: &str, aux_path: Option<&str>) {
1719
// Need to be sure to put both the lib_path and the aux path in the dylib
1820
// search path for the child.
1921
let mut path = DynamicLibrary::search_path();
2022
match aux_path {
21-
Some(p) => path.insert(0, PathBuf::from(p)),
23+
Some(p) => path.insert(0, Path::new(p)),
2224
None => {}
2325
}
24-
path.insert(0, PathBuf::from(lib_path));
26+
path.insert(0, Path::new(lib_path));
2527

2628
// Add the new dylib search path var
2729
let var = DynamicLibrary::envvar();
2830
let newpath = DynamicLibrary::create_path(&path);
29-
let newpath = newpath.to_str().unwrap().to_string();
31+
let newpath = String::from_utf8(newpath).unwrap();
3032
cmd.env(var, &newpath);
3133
}
3234

branches/snap-stage3/src/compiletest/runtest.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -758,7 +758,7 @@ fn run_debuginfo_lldb_test(config: &Config, props: &TestProps, testfile: &Path)
758758
struct DebuggerCommands {
759759
commands: Vec<String>,
760760
check_lines: Vec<String>,
761-
breakpoint_lines: Vec<usize>,
761+
breakpoint_lines: Vec<uint>,
762762
}
763763

764764
fn parse_debugger_commands(file_path: &Path, debugger_prefix: &str)
@@ -1036,7 +1036,7 @@ fn is_compiler_error_or_warning(line: &str) -> bool {
10361036
scan_string(line, "warning", &mut i));
10371037
}
10381038

1039-
fn scan_until_char(haystack: &str, needle: char, idx: &mut usize) -> bool {
1039+
fn scan_until_char(haystack: &str, needle: char, idx: &mut uint) -> bool {
10401040
if *idx >= haystack.len() {
10411041
return false;
10421042
}
@@ -1048,7 +1048,7 @@ fn scan_until_char(haystack: &str, needle: char, idx: &mut usize) -> bool {
10481048
return true;
10491049
}
10501050

1051-
fn scan_char(haystack: &str, needle: char, idx: &mut usize) -> bool {
1051+
fn scan_char(haystack: &str, needle: char, idx: &mut uint) -> bool {
10521052
if *idx >= haystack.len() {
10531053
return false;
10541054
}
@@ -1060,7 +1060,7 @@ fn scan_char(haystack: &str, needle: char, idx: &mut usize) -> bool {
10601060
return true;
10611061
}
10621062

1063-
fn scan_integer(haystack: &str, idx: &mut usize) -> bool {
1063+
fn scan_integer(haystack: &str, idx: &mut uint) -> bool {
10641064
let mut i = *idx;
10651065
while i < haystack.len() {
10661066
let ch = haystack.char_at(i);
@@ -1076,7 +1076,7 @@ fn scan_integer(haystack: &str, idx: &mut usize) -> bool {
10761076
return true;
10771077
}
10781078

1079-
fn scan_string(haystack: &str, needle: &str, idx: &mut usize) -> bool {
1079+
fn scan_string(haystack: &str, needle: &str, idx: &mut uint) -> bool {
10801080
let mut haystack_i = *idx;
10811081
let mut needle_i = 0;
10821082
while needle_i < needle.len() {
@@ -1725,7 +1725,7 @@ fn disassemble_extract(config: &Config, _props: &TestProps,
17251725
}
17261726

17271727

1728-
fn count_extracted_lines(p: &Path) -> usize {
1728+
fn count_extracted_lines(p: &Path) -> uint {
17291729
let mut x = Vec::new();
17301730
File::open(&p.with_extension("ll")).unwrap().read_to_end(&mut x).unwrap();
17311731
let x = str::from_utf8(&x).unwrap();

branches/snap-stage3/src/compiletest/util.rs

Lines changed: 16 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -13,34 +13,33 @@ use common::Config;
1313

1414
/// Conversion table from triple OS name to Rust SYSNAME
1515
const OS_TABLE: &'static [(&'static str, &'static str)] = &[
16-
("android", "android"),
17-
("bitrig", "bitrig"),
18-
("darwin", "macos"),
19-
("dragonfly", "dragonfly"),
20-
("freebsd", "freebsd"),
21-
("ios", "ios"),
22-
("linux", "linux"),
2316
("mingw32", "windows"),
24-
("openbsd", "openbsd"),
2517
("win32", "windows"),
2618
("windows", "windows"),
19+
("darwin", "macos"),
20+
("android", "android"),
21+
("linux", "linux"),
22+
("freebsd", "freebsd"),
23+
("dragonfly", "dragonfly"),
24+
("bitrig", "bitrig"),
25+
("openbsd", "openbsd"),
2726
];
2827

2928
const ARCH_TABLE: &'static [(&'static str, &'static str)] = &[
30-
("aarch64", "aarch64"),
31-
("amd64", "x86_64"),
32-
("arm", "arm"),
33-
("arm64", "aarch64"),
34-
("hexagon", "hexagon"),
3529
("i386", "x86"),
3630
("i686", "x86"),
31+
("amd64", "x86_64"),
32+
("x86_64", "x86_64"),
33+
("sparc", "sparc"),
34+
("powerpc", "powerpc"),
35+
("arm64", "aarch64"),
36+
("arm", "arm"),
37+
("aarch64", "aarch64"),
3738
("mips", "mips"),
39+
("xcore", "xcore"),
3840
("msp430", "msp430"),
39-
("powerpc", "powerpc"),
41+
("hexagon", "hexagon"),
4042
("s390x", "systemz"),
41-
("sparc", "sparc"),
42-
("x86_64", "x86_64"),
43-
("xcore", "xcore"),
4443
];
4544

4645
pub fn get_os(triple: &str) -> &'static str {

0 commit comments

Comments
 (0)