test: Update tests to use the new syntax.
This commit is contained in:
parent
c10e0cb9c9
commit
1be40be613
272 changed files with 564 additions and 564 deletions
|
@ -8,7 +8,7 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
use core::comm::*;
|
||||
use std::comm::*;
|
||||
|
||||
pub fn foo<T:Owned + Copy>(x: T) -> Port<T> {
|
||||
let (p, c) = stream();
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
use core::to_str::*;
|
||||
use std::to_str::*;
|
||||
|
||||
pub mod kitty {
|
||||
pub struct cat {
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
uuid = "54cc1bc9-02b8-447c-a227-75ebc923bc29")];
|
||||
#[crate_type = "lib"];
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
struct arc_destruct<T> {
|
||||
_data: int,
|
||||
|
|
|
@ -11,9 +11,9 @@
|
|||
#[link(name = "req")];
|
||||
#[crate_type = "lib"];
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
use core::hashmap::HashMap;
|
||||
use std::hashmap::HashMap;
|
||||
|
||||
pub type header_map = HashMap<~str, @mut ~[@~str]>;
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
use core::cmp::Eq;
|
||||
use std::cmp::Eq;
|
||||
|
||||
pub trait MyNum : Add<Self,Self> + Sub<Self,Self> + Mul<Self,Self> + Eq {
|
||||
}
|
||||
|
|
|
@ -8,14 +8,14 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
use core::io;
|
||||
use std::time;
|
||||
use std::treemap::TreeMap;
|
||||
use core::hashmap::{HashMap, HashSet};
|
||||
use core::trie::TrieMap;
|
||||
use core::rand::Rng;
|
||||
use std::io;
|
||||
use extra::time;
|
||||
use extra::treemap::TreeMap;
|
||||
use std::hashmap::{HashMap, HashSet};
|
||||
use std::trie::TrieMap;
|
||||
use std::rand::Rng;
|
||||
|
||||
fn timed(label: &str, f: &fn()) {
|
||||
let start = time::precise_time_s();
|
||||
|
@ -103,7 +103,7 @@ fn main() {
|
|||
let mut rand = vec::with_capacity(n_keys);
|
||||
|
||||
{
|
||||
let mut rng = core::rand::IsaacRng::new_seeded([1, 1, 1, 1, 1, 1, 1]);
|
||||
let mut rng = std::rand::IsaacRng::new_seeded([1, 1, 1, 1, 1, 1, 1]);
|
||||
let mut set = HashSet::new();
|
||||
while set.len() != n_keys {
|
||||
let next = rng.next() as uint;
|
||||
|
|
|
@ -8,10 +8,10 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
extern mod std;
|
||||
use core::hashmap::HashSet;
|
||||
use std::bitv::BitvSet;
|
||||
use std::treemap::TreeSet;
|
||||
extern mod extra;
|
||||
use std::hashmap::HashSet;
|
||||
use extra::bitv::BitvSet;
|
||||
use extra::treemap::TreeSet;
|
||||
|
||||
struct Results {
|
||||
sequential_ints: float,
|
||||
|
@ -24,9 +24,9 @@ struct Results {
|
|||
}
|
||||
|
||||
fn timed(result: &mut float, op: &fn()) {
|
||||
let start = std::time::precise_time_s();
|
||||
let start = extra::time::precise_time_s();
|
||||
op();
|
||||
let end = std::time::precise_time_s();
|
||||
let end = extra::time::precise_time_s();
|
||||
*result = (end - start);
|
||||
}
|
||||
|
||||
|
@ -168,7 +168,7 @@ fn main() {
|
|||
let mut results = empty_results();
|
||||
results.bench_int(&mut rng, num_keys, max, || HashSet::new::<uint>());
|
||||
results.bench_str(&mut rng, num_keys, || HashSet::new::<~str>());
|
||||
write_results("core::hashmap::HashSet", &results);
|
||||
write_results("std::hashmap::HashSet", &results);
|
||||
}
|
||||
|
||||
{
|
||||
|
@ -176,13 +176,13 @@ fn main() {
|
|||
let mut results = empty_results();
|
||||
results.bench_int(&mut rng, num_keys, max, || TreeSet::new::<uint>());
|
||||
results.bench_str(&mut rng, num_keys, || TreeSet::new::<~str>());
|
||||
write_results("std::treemap::TreeSet", &results);
|
||||
write_results("extra::treemap::TreeSet", &results);
|
||||
}
|
||||
|
||||
{
|
||||
let mut rng = rand::IsaacRng::new_seeded(seed);
|
||||
let mut results = empty_results();
|
||||
results.bench_int(&mut rng, num_keys, max, || BitvSet::new());
|
||||
write_results("std::bitv::BitvSet", &results);
|
||||
write_results("extra::bitv::BitvSet", &results);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -8,13 +8,13 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
// Microbenchmarks for various functions in core and std
|
||||
// Microbenchmarks for various functions in std and extra
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
use std::time::precise_time_s;
|
||||
use core::rand::RngUtil;
|
||||
use core::util;
|
||||
use extra::time::precise_time_s;
|
||||
use std::rand::RngUtil;
|
||||
use std::util;
|
||||
|
||||
macro_rules! bench (
|
||||
($id:ident) => (maybe_run_test(argv, stringify!($id).to_owned(), $id))
|
||||
|
|
|
@ -16,14 +16,14 @@ An implementation of the Graph500 Breadth First Search problem in Rust.
|
|||
|
||||
*/
|
||||
|
||||
extern mod std;
|
||||
use std::arc;
|
||||
use std::time;
|
||||
use std::deque::Deque;
|
||||
use std::par;
|
||||
use core::hashmap::HashSet;
|
||||
use core::int::abs;
|
||||
use core::rand::RngUtil;
|
||||
extern mod extra;
|
||||
use extra::arc;
|
||||
use extra::time;
|
||||
use extra::deque::Deque;
|
||||
use extra::par;
|
||||
use std::hashmap::HashSet;
|
||||
use std::int::abs;
|
||||
use std::rand::RngUtil;
|
||||
|
||||
type node_id = i64;
|
||||
type graph = ~[~[node_id]];
|
||||
|
|
|
@ -18,11 +18,11 @@
|
|||
// different scalability characteristics compared to the select
|
||||
// version.
|
||||
|
||||
extern mod std;
|
||||
use core::io::Writer;
|
||||
use core::io::WriterUtil;
|
||||
extern mod extra;
|
||||
use std::io::Writer;
|
||||
use std::io::WriterUtil;
|
||||
|
||||
use core::comm::{Port, Chan, SharedChan};
|
||||
use std::comm::{Port, Chan, SharedChan};
|
||||
|
||||
macro_rules! move_out (
|
||||
{ $x:expr } => { unsafe { let y = *ptr::to_unsafe_ptr(&($x)); y } }
|
||||
|
@ -61,7 +61,7 @@ fn run(args: &[~str]) {
|
|||
let size = uint::from_str(args[1]).get();
|
||||
let workers = uint::from_str(args[2]).get();
|
||||
let num_bytes = 100;
|
||||
let start = std::time::precise_time_s();
|
||||
let start = extra::time::precise_time_s();
|
||||
let mut worker_results = ~[];
|
||||
for uint::range(0, workers) |_i| {
|
||||
let to_child = to_child.clone();
|
||||
|
@ -87,7 +87,7 @@ fn run(args: &[~str]) {
|
|||
to_child.send(stop);
|
||||
move_out!(to_child);
|
||||
let result = from_child.recv();
|
||||
let end = std::time::precise_time_s();
|
||||
let end = extra::time::precise_time_s();
|
||||
let elapsed = end - start;
|
||||
io::stdout().write_str(fmt!("Count is %?\n", result));
|
||||
io::stdout().write_str(fmt!("Test took %? seconds\n", elapsed));
|
||||
|
|
|
@ -14,11 +14,11 @@
|
|||
//
|
||||
// I *think* it's the same, more or less.
|
||||
|
||||
extern mod std;
|
||||
use core::io::Writer;
|
||||
use core::io::WriterUtil;
|
||||
extern mod extra;
|
||||
use std::io::Writer;
|
||||
use std::io::WriterUtil;
|
||||
|
||||
use core::comm::{Port, PortSet, Chan, stream};
|
||||
use std::comm::{Port, PortSet, Chan, stream};
|
||||
|
||||
macro_rules! move_out (
|
||||
{ $x:expr } => { unsafe { let y = *ptr::to_unsafe_ptr(&($x)); y } }
|
||||
|
@ -57,7 +57,7 @@ fn run(args: &[~str]) {
|
|||
let size = uint::from_str(args[1]).get();
|
||||
let workers = uint::from_str(args[2]).get();
|
||||
let num_bytes = 100;
|
||||
let start = std::time::precise_time_s();
|
||||
let start = extra::time::precise_time_s();
|
||||
let mut worker_results = ~[];
|
||||
for uint::range(0, workers) |_i| {
|
||||
let (from_parent_, to_child) = stream();
|
||||
|
@ -84,7 +84,7 @@ fn run(args: &[~str]) {
|
|||
to_child.send(stop);
|
||||
move_out!(to_child);
|
||||
let result = from_child.recv();
|
||||
let end = std::time::precise_time_s();
|
||||
let end = extra::time::precise_time_s();
|
||||
let elapsed = end - start;
|
||||
io::stdout().write_str(fmt!("Count is %?\n", result));
|
||||
io::stdout().write_str(fmt!("Test took %? seconds\n", elapsed));
|
||||
|
|
|
@ -15,11 +15,11 @@
|
|||
|
||||
// This also serves as a pipes test, because ARCs are implemented with pipes.
|
||||
|
||||
extern mod std;
|
||||
use std::time;
|
||||
use std::arc;
|
||||
use std::future;
|
||||
use core::cell::Cell;
|
||||
extern mod extra;
|
||||
use extra::time;
|
||||
use extra::arc;
|
||||
use extra::future;
|
||||
use std::cell::Cell;
|
||||
|
||||
// A poor man's pipe.
|
||||
type pipe = arc::MutexARC<~[uint]>;
|
||||
|
|
|
@ -16,13 +16,13 @@
|
|||
|
||||
// This version uses automatically compiled channel contracts.
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
use core::cell::Cell;
|
||||
use core::pipes::recv;
|
||||
use core::util;
|
||||
use std::time;
|
||||
use std::future;
|
||||
use std::cell::Cell;
|
||||
use std::pipes::recv;
|
||||
use std::util;
|
||||
use extra::time;
|
||||
use extra::future;
|
||||
|
||||
proto! ring (
|
||||
num:send {
|
||||
|
|
|
@ -15,12 +15,12 @@
|
|||
|
||||
// This also serves as a pipes test, because ARCs are implemented with pipes.
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
use core::cell::Cell;
|
||||
use std::time;
|
||||
use std::arc;
|
||||
use std::future;
|
||||
use std::cell::Cell;
|
||||
use extra::time;
|
||||
use extra::arc;
|
||||
use extra::future;
|
||||
|
||||
// A poor man's pipe.
|
||||
type pipe = arc::RWARC<~[uint]>;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
// Perlin noise benchmark from https://gist.github.com/1170424
|
||||
|
||||
use core::rand::{Rng, RngUtil};
|
||||
use std::rand::{Rng, RngUtil};
|
||||
|
||||
struct Vec2 {
|
||||
x: f32,
|
||||
|
|
|
@ -12,11 +12,11 @@
|
|||
|
||||
// xfail-pretty
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
use core::cell::Cell;
|
||||
use core::pipes::*;
|
||||
use std::time::precise_time_s;
|
||||
use std::cell::Cell;
|
||||
use std::pipes::*;
|
||||
use extra::time::precise_time_s;
|
||||
|
||||
proto! pingpong (
|
||||
ping: send {
|
||||
|
@ -117,10 +117,10 @@ pub fn spawn_service_recv<T:Owned,Tb:Owned>(
|
|||
client
|
||||
}
|
||||
|
||||
fn switch<T:Owned,Tb:Owned,U>(endp: core::pipes::RecvPacketBuffered<T, Tb>,
|
||||
fn switch<T:Owned,Tb:Owned,U>(endp: std::pipes::RecvPacketBuffered<T, Tb>,
|
||||
f: &fn(v: Option<T>) -> U)
|
||||
-> U {
|
||||
f(core::pipes::try_recv(endp))
|
||||
f(std::pipes::try_recv(endp))
|
||||
}
|
||||
|
||||
// Here's the benchmark
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
fn ack(m: int, n: int) -> int {
|
||||
if m == 0 {
|
||||
|
|
|
@ -12,8 +12,8 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
extern mod std;
|
||||
use std::arena;
|
||||
extern mod extra;
|
||||
use extra::arena;
|
||||
|
||||
enum tree<'self> {
|
||||
nil,
|
||||
|
|
|
@ -10,10 +10,10 @@
|
|||
|
||||
// chameneos
|
||||
|
||||
extern mod std;
|
||||
use std::sort;
|
||||
use core::cell::Cell;
|
||||
use core::comm::*;
|
||||
extern mod extra;
|
||||
use extra::sort;
|
||||
use std::cell::Cell;
|
||||
use std::comm::*;
|
||||
|
||||
fn print_complements() {
|
||||
let all = ~[Blue, Red, Yellow];
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
use core::from_str::FromStr;
|
||||
use core::i32::range;
|
||||
use core::vec::MutableVector;
|
||||
use std::from_str::FromStr;
|
||||
use std::i32::range;
|
||||
use std::vec::MutableVector;
|
||||
|
||||
fn max(a: i32, b: i32) -> i32 {
|
||||
if a > b {
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
use core::cast::transmute;
|
||||
use core::from_str::FromStr;
|
||||
use core::libc::{FILE, STDOUT_FILENO, c_int, fdopen, fputc, fputs, fwrite, size_t};
|
||||
use core::uint::{min, range};
|
||||
use core::vec::bytes::copy_memory;
|
||||
use std::cast::transmute;
|
||||
use std::from_str::FromStr;
|
||||
use std::libc::{FILE, STDOUT_FILENO, c_int, fdopen, fputc, fputs, fwrite, size_t};
|
||||
use std::uint::{min, range};
|
||||
use std::vec::bytes::copy_memory;
|
||||
|
||||
static LINE_LEN: uint = 60;
|
||||
static LOOKUP_SIZE: uint = 4 * 1024;
|
||||
|
|
|
@ -15,8 +15,8 @@
|
|||
* Computer Language Benchmarks Game
|
||||
* http://shootout.alioth.debian.org/
|
||||
*/
|
||||
extern mod std;
|
||||
use core::rand::Rng;
|
||||
extern mod extra;
|
||||
use std::rand::Rng;
|
||||
|
||||
fn LINE_LENGTH() -> uint { return 60u; }
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
fn fib(n: int) -> int {
|
||||
if n < 2 {
|
||||
|
|
|
@ -11,13 +11,13 @@
|
|||
// xfail-pretty (extra blank line is inserted in vec::mapi call)
|
||||
// multi tasking k-nucleotide
|
||||
|
||||
extern mod std;
|
||||
use std::sort;
|
||||
use core::hashmap::HashMap;
|
||||
use core::io::ReaderUtil;
|
||||
use core::comm::{stream, Port, Chan};
|
||||
use core::cmp::Ord;
|
||||
use core::util;
|
||||
extern mod extra;
|
||||
use extra::sort;
|
||||
use std::hashmap::HashMap;
|
||||
use std::io::ReaderUtil;
|
||||
use std::comm::{stream, Port, Chan};
|
||||
use std::cmp::Ord;
|
||||
use std::util;
|
||||
|
||||
// given a map, print a sorted version of it
|
||||
fn sort_and_fmt(mm: &HashMap<~[u8], uint>, total: uint) -> ~str {
|
||||
|
|
|
@ -1,15 +1,15 @@
|
|||
// xfail-test
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
use core::cast::transmute;
|
||||
use core::i32::range;
|
||||
use core::libc::{STDIN_FILENO, c_int, fdopen, fgets, fileno, fopen, fstat};
|
||||
use core::libc::{stat, strlen};
|
||||
use core::ptr::null;
|
||||
use core::unstable::intrinsics::init;
|
||||
use core::vec::{reverse, slice};
|
||||
use std::sort::quick_sort3;
|
||||
use std::cast::transmute;
|
||||
use std::i32::range;
|
||||
use std::libc::{STDIN_FILENO, c_int, fdopen, fgets, fileno, fopen, fstat};
|
||||
use std::libc::{stat, strlen};
|
||||
use std::ptr::null;
|
||||
use std::unstable::intrinsics::init;
|
||||
use std::vec::{reverse, slice};
|
||||
use extra::sort::quick_sort3;
|
||||
|
||||
static LINE_LEN: uint = 80;
|
||||
static TABLE: [u8, ..4] = [ 'A' as u8, 'C' as u8, 'G' as u8, 'T' as u8 ];
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
use core::cast::transmute;
|
||||
use core::from_str::FromStr;
|
||||
use core::i32::range;
|
||||
use core::libc::{STDOUT_FILENO, c_int, fdopen, fputc};
|
||||
use std::cast::transmute;
|
||||
use std::from_str::FromStr;
|
||||
use std::i32::range;
|
||||
use std::libc::{STDOUT_FILENO, c_int, fdopen, fputc};
|
||||
|
||||
static ITER: uint = 50;
|
||||
static LIMIT: f64 = 2.0;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
use core::from_str::FromStr;
|
||||
use core::uint::range;
|
||||
use std::from_str::FromStr;
|
||||
use std::uint::range;
|
||||
|
||||
static PI: f64 = 3.141592653589793;
|
||||
static SOLAR_MASS: f64 = 4.0 * PI * PI;
|
||||
|
|
|
@ -19,14 +19,14 @@
|
|||
|
||||
*/
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
use std::{time, getopts};
|
||||
use core::int::range;
|
||||
use core::comm::*;
|
||||
use core::io::WriterUtil;
|
||||
use extra::{time, getopts};
|
||||
use std::int::range;
|
||||
use std::comm::*;
|
||||
use std::io::WriterUtil;
|
||||
|
||||
use core::result::{Ok, Err};
|
||||
use std::result::{Ok, Err};
|
||||
|
||||
fn fib(n: int) -> int {
|
||||
fn pfib(c: &Chan<int>, n: int) {
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
// xfail-test
|
||||
|
||||
use core::cast::transmute;
|
||||
use core::from_str::FromStr;
|
||||
use core::libc::{STDOUT_FILENO, c_char, c_int, c_uint, c_void, fdopen, fputc};
|
||||
use core::libc::{fputs};
|
||||
use core::ptr::null;
|
||||
use std::cast::transmute;
|
||||
use std::from_str::FromStr;
|
||||
use std::libc::{STDOUT_FILENO, c_char, c_int, c_uint, c_void, fdopen, fputc};
|
||||
use std::libc::{fputs};
|
||||
use std::ptr::null;
|
||||
|
||||
struct mpz_t {
|
||||
_mp_alloc: c_int,
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
// xfail-pretty
|
||||
// xfail-test
|
||||
|
||||
use core::cast::transmute;
|
||||
use core::libc::{STDOUT_FILENO, c_int, fdopen, fgets, fopen, fputc, fwrite};
|
||||
use core::libc::{size_t};
|
||||
use core::ptr::null;
|
||||
use core::vec::{capacity, reserve, reserve_at_least};
|
||||
use core::vec::raw::set_len;
|
||||
use std::cast::transmute;
|
||||
use std::libc::{STDOUT_FILENO, c_int, fdopen, fgets, fopen, fputc, fwrite};
|
||||
use std::libc::{size_t};
|
||||
use std::ptr::null;
|
||||
use std::vec::{capacity, reserve, reserve_at_least};
|
||||
use std::vec::raw::set_len;
|
||||
|
||||
static LINE_LEN: u32 = 80;
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
use core::from_str::FromStr;
|
||||
use core::iter::ExtendedMutableIter;
|
||||
use std::from_str::FromStr;
|
||||
use std::iter::ExtendedMutableIter;
|
||||
|
||||
#[inline]
|
||||
fn A(i: i32, j: i32) -> i32 {
|
||||
|
|
|
@ -10,9 +10,9 @@
|
|||
|
||||
// Microbenchmark for the smallintmap library
|
||||
|
||||
extern mod std;
|
||||
use std::smallintmap::SmallIntMap;
|
||||
use core::io::WriterUtil;
|
||||
extern mod extra;
|
||||
use extra::smallintmap::SmallIntMap;
|
||||
use std::io::WriterUtil;
|
||||
|
||||
fn append_sequential(min: uint, max: uint, map: &mut SmallIntMap<uint>) {
|
||||
for uint::range(min, max) |i| {
|
||||
|
@ -43,11 +43,11 @@ fn main() {
|
|||
|
||||
for uint::range(0u, rep) |_r| {
|
||||
let mut map = SmallIntMap::new();
|
||||
let start = std::time::precise_time_s();
|
||||
let start = extra::time::precise_time_s();
|
||||
append_sequential(0u, max, &mut map);
|
||||
let mid = std::time::precise_time_s();
|
||||
let mid = extra::time::precise_time_s();
|
||||
check_sequential(0u, max, &map);
|
||||
let end = std::time::precise_time_s();
|
||||
let end = extra::time::precise_time_s();
|
||||
|
||||
checkf += (end - mid) as float;
|
||||
appendf += (mid - start) as float;
|
||||
|
|
|
@ -10,11 +10,11 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
use core::io::{ReaderUtil, WriterUtil};
|
||||
use core::io;
|
||||
use core::unstable::intrinsics::cttz16;
|
||||
use std::io::{ReaderUtil, WriterUtil};
|
||||
use std::io;
|
||||
use std::unstable::intrinsics::cttz16;
|
||||
|
||||
// Computes a single solution to a given 9x9 sudoku
|
||||
//
|
||||
|
|
|
@ -10,10 +10,10 @@
|
|||
|
||||
// xfail-win32
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
use std::list::{List, Cons, Nil};
|
||||
use std::time::precise_time_s;
|
||||
use extra::list::{List, Cons, Nil};
|
||||
use extra::time::precise_time_s;
|
||||
|
||||
enum UniqueList {
|
||||
ULNil, ULCons(~UniqueList)
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
//
|
||||
// The filename is a song reference; google it in quotes.
|
||||
|
||||
use core::cell::Cell;
|
||||
use std::cell::Cell;
|
||||
|
||||
fn child_generation(gens_left: uint, c: comm::Chan<()>) {
|
||||
// This used to be O(n^2) in the number of generations that ever existed.
|
||||
|
|
|
@ -22,7 +22,7 @@
|
|||
// Creates in the background 'num_tasks' tasks, all blocked forever.
|
||||
// Doesn't return until all such tasks are ready, but doesn't block forever itself.
|
||||
|
||||
use core::comm::*;
|
||||
use std::comm::*;
|
||||
|
||||
fn grandchild_group(num_tasks: uint) {
|
||||
let (po, ch) = stream();
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
|
||||
// Test for concurrent tasks
|
||||
|
||||
use core::comm::*;
|
||||
use std::comm::*;
|
||||
|
||||
fn calc(children: uint, parent_wait_chan: &Chan<Chan<Chan<int>>>) {
|
||||
|
||||
|
|
|
@ -10,8 +10,8 @@
|
|||
|
||||
// xfail-test
|
||||
// error-pattern: instantiating a type parameter with an incompatible type
|
||||
extern mod std;
|
||||
use std::arc::rw_arc;
|
||||
extern mod extra;
|
||||
use extra::arc::rw_arc;
|
||||
|
||||
fn main() {
|
||||
let arc1 = ~rw_arc(true);
|
||||
|
|
|
@ -9,8 +9,8 @@
|
|||
// except according to those terms.
|
||||
|
||||
// error-pattern: reference is not valid outside of its lifetime
|
||||
extern mod std;
|
||||
use std::arc;
|
||||
extern mod extra;
|
||||
use extra::arc;
|
||||
fn main() {
|
||||
let x = ~arc::RWARC(1);
|
||||
let mut y = None;
|
||||
|
|
|
@ -8,8 +8,8 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
extern mod std;
|
||||
use std::arc;
|
||||
extern mod extra;
|
||||
use extra::arc;
|
||||
fn main() {
|
||||
let x = ~arc::RWARC(1);
|
||||
let mut y = None;
|
||||
|
|
|
@ -9,8 +9,8 @@
|
|||
// except according to those terms.
|
||||
|
||||
// error-pattern: reference is not valid outside of its lifetime
|
||||
extern mod std;
|
||||
use std::arc;
|
||||
extern mod extra;
|
||||
use extra::arc;
|
||||
fn main() {
|
||||
let x = ~arc::RWARC(1);
|
||||
let mut y = None;
|
||||
|
|
|
@ -9,8 +9,8 @@
|
|||
// except according to those terms.
|
||||
|
||||
// error-pattern: reference is not valid outside of its lifetime
|
||||
extern mod std;
|
||||
use std::arc;
|
||||
extern mod extra;
|
||||
use extra::arc;
|
||||
fn main() {
|
||||
let x = ~arc::RWARC(1);
|
||||
let mut y = None;
|
||||
|
|
|
@ -9,8 +9,8 @@
|
|||
// except according to those terms.
|
||||
|
||||
// error-pattern: reference is not valid outside of its lifetime
|
||||
extern mod std;
|
||||
use std::arc;
|
||||
extern mod extra;
|
||||
use extra::arc;
|
||||
fn main() {
|
||||
let x = ~arc::RWARC(1);
|
||||
let mut y = None;
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
|
||||
//buggy.rs
|
||||
|
||||
use core::hashmap::HashMap;
|
||||
use std::hashmap::HashMap;
|
||||
|
||||
fn main() {
|
||||
let mut buggy_map :HashMap<uint, &uint> =
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
use core::hashmap::HashSet;
|
||||
use std::hashmap::HashSet;
|
||||
|
||||
struct Foo {
|
||||
n: HashSet<int>,
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
use core::either::{Either, Left, Right};
|
||||
use std::either::{Either, Left, Right};
|
||||
|
||||
fn f(x: &mut Either<int,float>, y: &Either<int,float>) -> int {
|
||||
match *y {
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
fn main() {
|
||||
let foo = ~3;
|
||||
|
|
|
@ -2,7 +2,7 @@ fn main() {
|
|||
let mut a = [1, 2, 3, 4];
|
||||
let t = match a {
|
||||
[1, 2, ..tail] => tail,
|
||||
_ => core::util::unreachable()
|
||||
_ => std::util::unreachable()
|
||||
};
|
||||
a[0] = 0; //~ ERROR cannot assign to `a[]` because it is borrowed
|
||||
t[0];
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
|
||||
// Testing that we can't store a borrowed pointer it task-local storage
|
||||
|
||||
use core::local_data::*;
|
||||
use std::local_data::*;
|
||||
|
||||
fn key(_x: @&int) { }
|
||||
|
||||
|
|
|
@ -10,6 +10,6 @@
|
|||
|
||||
// error-pattern:not enough arguments
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
fn main() { let s = fmt!("%s%s%s", "test", "test"); }
|
||||
|
|
|
@ -10,6 +10,6 @@
|
|||
|
||||
// error-pattern:too many arguments
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
fn main() { let s = fmt!("%s", "test", "test"); }
|
||||
|
|
|
@ -8,6 +8,6 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
// error-pattern:failed to find an implementation of trait core::sys::FailWithCause for int
|
||||
// error-pattern:failed to find an implementation of trait std::sys::FailWithCause for int
|
||||
|
||||
fn main() { fail!(5); }
|
||||
|
|
|
@ -8,5 +8,5 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
// error-pattern:failed to find an implementation of trait core::sys::FailWithCause for ~[int]
|
||||
// error-pattern:failed to find an implementation of trait std::sys::FailWithCause for ~[int]
|
||||
fn main() { fail!(~[0i]); }
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
use core::unstable::intrinsics::{init, forget};
|
||||
use std::unstable::intrinsics::{init, forget};
|
||||
|
||||
// Test that the `forget` and `init` intrinsics are really unsafe
|
||||
pub fn main() {
|
||||
|
|
|
@ -13,5 +13,5 @@
|
|||
fn main() {
|
||||
let x: Option<uint>;
|
||||
x = 5;
|
||||
//~^ ERROR mismatched types: expected `core::option::Option<uint>`
|
||||
//~^ ERROR mismatched types: expected `std::option::Option<uint>`
|
||||
}
|
||||
|
|
|
@ -10,11 +10,11 @@
|
|||
|
||||
// Test that we use fully-qualified type names in error messages.
|
||||
|
||||
use core::task::Task;
|
||||
use std::task::Task;
|
||||
|
||||
fn bar(x: uint) -> Task {
|
||||
return x;
|
||||
//~^ ERROR mismatched types: expected `core::task::Task`
|
||||
//~^ ERROR mismatched types: expected `std::task::Task`
|
||||
}
|
||||
|
||||
fn main() {
|
||||
|
|
|
@ -11,8 +11,8 @@
|
|||
pub mod stream {
|
||||
pub enum Stream<T:Owned> { send(T, ::stream::server::Stream<T>), }
|
||||
pub mod server {
|
||||
use core::option;
|
||||
use core::pipes;
|
||||
use std::option;
|
||||
use std::pipes;
|
||||
|
||||
pub impl<T:Owned> Stream<T> {
|
||||
pub fn recv() -> extern fn(v: Stream<T>) -> ::stream::Stream<T> {
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
fn siphash(k0 : u64) {
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
fn siphash<T>() {
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
trait siphash {
|
||||
fn result(&self) -> u64;
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
trait SipHash {
|
||||
fn reset(&self);
|
||||
|
|
|
@ -8,9 +8,9 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
use std;
|
||||
use extra;
|
||||
|
||||
struct Deserializer : std::serialization::deserializer{ //~ ERROR obsolete syntax: class traits
|
||||
struct Deserializer : extra::serialization::deserializer{ //~ ERROR obsolete syntax: class traits
|
||||
x: ()
|
||||
}
|
||||
|
||||
|
@ -18,7 +18,7 @@ struct Foo {
|
|||
a: ()
|
||||
}
|
||||
|
||||
fn deserialize_foo<__D: std::serialization::deserializer>(__d: __D) {
|
||||
fn deserialize_foo<__D: extra::serialization::deserializer>(__d: __D) {
|
||||
}
|
||||
|
||||
fn main() { let des = Deserializer(); let foo = deserialize_foo(des); }
|
||||
|
|
|
@ -10,6 +10,6 @@
|
|||
|
||||
fn main() {
|
||||
match None {
|
||||
Err(_) => () //~ ERROR mismatched types: expected `core::option::Option<<V1>>` but found `core::result::Result<<V2>,<V3>>`
|
||||
Err(_) => () //~ ERROR mismatched types: expected `std::option::Option<<V1>>` but found `std::result::Result<<V2>,<V3>>`
|
||||
}
|
||||
}
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
use core::cmp::Eq;
|
||||
use std::cmp::Eq;
|
||||
|
||||
trait Hahaha: Eq + Eq + Eq + Eq + Eq + //~ ERROR Duplicate supertrait
|
||||
Eq + Eq + Eq + Eq + Eq + Eq + Eq + Eq + Eq + Eq + Eq + Eq + Eq +
|
||||
|
|
|
@ -8,8 +8,8 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
extern mod std;
|
||||
use core::cmp::Eq;
|
||||
extern mod extra;
|
||||
use std::cmp::Eq;
|
||||
|
||||
fn f<T:Eq>(o: &mut Option<T>) {
|
||||
assert!(*o == option::None);
|
||||
|
|
|
@ -12,7 +12,7 @@ struct S(Either<uint, uint>);
|
|||
|
||||
fn main() {
|
||||
match S(Left(5)) {
|
||||
Right(_) => {} //~ ERROR mismatched types: expected `S` but found `core::either::Either
|
||||
Right(_) => {} //~ ERROR mismatched types: expected `S` but found `std::either::Either
|
||||
_ => {}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -12,6 +12,6 @@ struct S(Either<uint, uint>);
|
|||
|
||||
fn main() {
|
||||
match *S(Left(5)) {
|
||||
S(_) => {} //~ ERROR mismatched types: expected `core::either::Either<uint,uint>` but found a structure pattern
|
||||
S(_) => {} //~ ERROR mismatched types: expected `std::either::Either<uint,uint>` but found a structure pattern
|
||||
}
|
||||
}
|
||||
|
|
|
@ -12,23 +12,23 @@
|
|||
|
||||
use cal = bar::c::cc;
|
||||
|
||||
use core::either::Right; //~ ERROR unused import
|
||||
use std::either::Right; //~ ERROR unused import
|
||||
|
||||
use core::util::*; // shouldn't get errors for not using
|
||||
use std::util::*; // shouldn't get errors for not using
|
||||
// everything imported
|
||||
|
||||
// Should get errors for both 'Some' and 'None'
|
||||
use core::option::{Some, None}; //~ ERROR unused import
|
||||
use std::option::{Some, None}; //~ ERROR unused import
|
||||
//~^ ERROR unused import
|
||||
|
||||
use core::io::ReaderUtil; //~ ERROR unused import
|
||||
use std::io::ReaderUtil; //~ ERROR unused import
|
||||
// Be sure that if we just bring some methods into scope that they're also
|
||||
// counted as being used.
|
||||
use core::io::WriterUtil;
|
||||
use std::io::WriterUtil;
|
||||
|
||||
// Make sure this import is warned about when at least one of its imported names
|
||||
// is unused
|
||||
use core::vec::{filter, map}; //~ ERROR unused import
|
||||
use std::vec::{filter, map}; //~ ERROR unused import
|
||||
|
||||
mod foo {
|
||||
pub struct Point{x: int, y: int}
|
||||
|
@ -37,7 +37,7 @@ mod foo {
|
|||
|
||||
mod bar {
|
||||
// Don't ignore on 'pub use' because we're not sure if it's used or not
|
||||
pub use core::cmp::Eq;
|
||||
pub use std::cmp::Eq;
|
||||
|
||||
pub mod c {
|
||||
use foo::Point;
|
||||
|
@ -47,7 +47,7 @@ mod bar {
|
|||
|
||||
#[allow(unused_imports)]
|
||||
mod foo {
|
||||
use core::cmp::Eq;
|
||||
use std::cmp::Eq;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -8,8 +8,8 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
use core::container::Map;
|
||||
use core::hashmap::HashMap;
|
||||
use std::container::Map;
|
||||
use std::hashmap::HashMap;
|
||||
|
||||
// Test that trait types printed in error msgs include the type arguments.
|
||||
|
||||
|
@ -17,5 +17,5 @@ fn main() {
|
|||
let x: @Map<~str, ~str> = @HashMap::new::<~str, ~str>() as
|
||||
@Map<~str, ~str>;
|
||||
let y: @Map<uint, ~str> = @x;
|
||||
//~^ ERROR mismatched types: expected `@core::container::Map<uint,~str>`
|
||||
//~^ ERROR mismatched types: expected `@std::container::Map<uint,~str>`
|
||||
}
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
// temporary kinds wound up being stored in a cache and used later.
|
||||
// See middle::ty::type_contents() for more information.
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
struct List { key: int, next: Option<~List> }
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
fn main() {
|
||||
unsafe fn f(v: *const int) {
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
// except according to those terms.
|
||||
|
||||
// error-pattern:declaration of `None` shadows
|
||||
use core::option::*;
|
||||
use std::option::*;
|
||||
|
||||
fn main() {
|
||||
let None: int = 42;
|
||||
|
|
|
@ -10,8 +10,8 @@
|
|||
|
||||
// error-pattern: use of moved value
|
||||
|
||||
extern mod std;
|
||||
use std::arc;
|
||||
extern mod extra;
|
||||
use extra::arc;
|
||||
|
||||
fn main() {
|
||||
let v = ~[1, 2, 3, 4, 5, 6, 7, 8, 9, 10];
|
||||
|
|
|
@ -8,8 +8,8 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
extern mod std;
|
||||
use std::arc;
|
||||
extern mod extra;
|
||||
use extra::arc;
|
||||
|
||||
fn main() {
|
||||
let v = ~[1, 2, 3, 4, 5, 6, 7, 8, 9, 10];
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
use core::cell::Cell;
|
||||
use std::cell::Cell;
|
||||
|
||||
struct Port<T>(@T);
|
||||
|
||||
|
|
|
@ -18,5 +18,5 @@ fn main() {
|
|||
// because the def_id associated with the type was
|
||||
// not convertible to a path.
|
||||
let x: int = noexporttypelib::foo();
|
||||
//~^ ERROR expected `int` but found `core::option::Option<int>`
|
||||
//~^ ERROR expected `int` but found `std::option::Option<int>`
|
||||
}
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
// except according to those terms.
|
||||
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
enum bar { t1((), Option<~[int]>), t2, }
|
||||
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
// error-pattern: mismatched types
|
||||
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
|
||||
// xfail-test Can't use syntax crate here
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
extern mod syntax;
|
||||
|
||||
use io::*;
|
||||
|
|
|
@ -10,10 +10,10 @@
|
|||
|
||||
// xfail-test Can't use syntax crate here
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
extern mod syntax;
|
||||
|
||||
use std::io::*;
|
||||
use extra::io::*;
|
||||
|
||||
use syntax::diagnostic;
|
||||
use syntax::ast;
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
// except according to those terms.
|
||||
|
||||
mod argparse {
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
pub struct Flag<'self> {
|
||||
name: &'self str,
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
fn main() {
|
||||
trait seq { }
|
||||
|
||||
|
|
|
@ -10,6 +10,6 @@
|
|||
|
||||
// error-pattern: mismatched types
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
fn main() { task::spawn(|| -> int { 10 }); }
|
||||
|
|
|
@ -9,8 +9,8 @@
|
|||
// except according to those terms.
|
||||
|
||||
// error-pattern: reference is not valid outside of its lifetime
|
||||
extern mod std;
|
||||
use std::sync;
|
||||
extern mod extra;
|
||||
use extra::sync;
|
||||
|
||||
fn main() {
|
||||
let m = ~sync::Mutex();
|
||||
|
|
|
@ -9,8 +9,8 @@
|
|||
// except according to those terms.
|
||||
|
||||
// error-pattern: reference is not valid outside of its lifetime
|
||||
extern mod std;
|
||||
use std::sync;
|
||||
extern mod extra;
|
||||
use extra::sync;
|
||||
fn main() {
|
||||
let x = ~sync::RWlock();
|
||||
let mut y = None;
|
||||
|
|
|
@ -9,8 +9,8 @@
|
|||
// except according to those terms.
|
||||
|
||||
// error-pattern: cannot infer an appropriate lifetime
|
||||
extern mod std;
|
||||
use std::sync;
|
||||
extern mod extra;
|
||||
use extra::sync;
|
||||
fn main() {
|
||||
let x = ~sync::RWlock();
|
||||
let mut y = None;
|
||||
|
|
|
@ -9,8 +9,8 @@
|
|||
// except according to those terms.
|
||||
|
||||
// error-pattern: reference is not valid outside of its lifetime
|
||||
extern mod std;
|
||||
use std::sync;
|
||||
extern mod extra;
|
||||
use extra::sync;
|
||||
fn main() {
|
||||
let x = ~sync::RWlock();
|
||||
let mut y = None;
|
||||
|
|
|
@ -9,8 +9,8 @@
|
|||
// except according to those terms.
|
||||
|
||||
// error-pattern: reference is not valid outside of its lifetime
|
||||
extern mod std;
|
||||
use std::sync;
|
||||
extern mod extra;
|
||||
use extra::sync;
|
||||
fn main() {
|
||||
let x = ~sync::RWlock();
|
||||
let mut y = None;
|
||||
|
|
|
@ -13,9 +13,9 @@
|
|||
|
||||
#[no_std];
|
||||
|
||||
extern mod core;
|
||||
extern mod std;
|
||||
|
||||
fn last<T>(v: ~[&T]) -> core::option::Option<T> {
|
||||
fn last<T>(v: ~[&T]) -> std::option::Option<T> {
|
||||
fail!();
|
||||
}
|
||||
|
||||
|
|
|
@ -10,6 +10,6 @@
|
|||
|
||||
// error-pattern:duplicate meta item `name`
|
||||
|
||||
extern mod std(name = "std", name = "nonstd");
|
||||
extern mod extra(name = "extra", name = "nonstd");
|
||||
|
||||
fn main() { }
|
||||
|
|
|
@ -8,8 +8,8 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
// error-pattern:can't find crate for `std`
|
||||
// error-pattern:can't find crate for `extra`
|
||||
|
||||
extern mod std(complex(meta(item)));
|
||||
extern mod extra(complex(meta(item)));
|
||||
|
||||
fn main() { }
|
||||
|
|
|
@ -10,12 +10,12 @@
|
|||
|
||||
// xfail-test
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
fn f() {
|
||||
}
|
||||
|
||||
use std::net; //~ ERROR view items must be declared at the top
|
||||
use extra::net; //~ ERROR view items must be declared at the top
|
||||
|
||||
fn main() {
|
||||
}
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
// Testing that runtime failure doesn't cause callbacks to abort abnormally.
|
||||
// Instead the failure will be delivered after the callbacks return.
|
||||
|
||||
use core::old_iter;
|
||||
use std::old_iter;
|
||||
|
||||
mod rustrt {
|
||||
pub extern {
|
||||
|
|
|
@ -9,5 +9,5 @@
|
|||
// except according to those terms.
|
||||
|
||||
// error-pattern:moop
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
fn main() { fail!("moop"); }
|
||||
|
|
|
@ -9,6 +9,6 @@
|
|||
// except according to those terms.
|
||||
|
||||
// error-pattern:meh
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
fn main() { let str_var: ~str = ~"meh"; fail!(fmt!("%s", str_var)); }
|
||||
|
|
|
@ -9,5 +9,5 @@
|
|||
// except according to those terms.
|
||||
|
||||
// error-pattern:moop
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
fn main() { for uint::range(0u, 10u) |_i| { fail!("moop"); } }
|
||||
|
|
|
@ -10,8 +10,8 @@
|
|||
|
||||
// error-pattern:explicit failure
|
||||
// Don't double free the string
|
||||
extern mod std;
|
||||
use core::io::ReaderUtil;
|
||||
extern mod extra;
|
||||
use std::io::ReaderUtil;
|
||||
|
||||
fn main() {
|
||||
do io::with_str_reader(~"") |rdr| {
|
||||
|
|
|
@ -10,8 +10,8 @@
|
|||
|
||||
// error-pattern:explicit failure
|
||||
|
||||
extern mod std;
|
||||
use std::arc;
|
||||
extern mod extra;
|
||||
use extra::arc;
|
||||
|
||||
enum e<T> { e(arc::ARC<T>) }
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
|
||||
|
||||
// error-pattern:1 == 2
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
fn child() { assert!((1 == 2)); }
|
||||
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
// See the hack in upcall_call_shim_on_c_stack where it messes
|
||||
// with the stack limit.
|
||||
|
||||
extern mod std;
|
||||
extern mod extra;
|
||||
|
||||
mod rustrt {
|
||||
pub extern {
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue