auto merge of #10032 : thestinger/rust/snapshot, r=huonw

This commit is contained in:
bors 2013-10-23 15:11:07 -07:00
commit e2428b791c
218 changed files with 395 additions and 60 deletions

View File

@ -40,7 +40,7 @@ c = open("tmp/run_pass_stage2.rc", "w")
i = 0
c.write("// AUTO-GENERATED FILE: DO NOT EDIT\n")
c.write("#[link(name=\"run_pass_stage2\", vers=\"0.1\")];\n")
c.write("#[feature(globs, macro_rules, struct_variant)];\n")
c.write("#[feature(globs, macro_rules, struct_variant, managed_boxes)];\n")
for t in stage2_tests:
p = os.path.join(run_pass, t)
p = p.replace("\\", "\\\\")
@ -52,7 +52,7 @@ c.close()
d = open("tmp/run_pass_stage2_driver.rs", "w")
d.write("// AUTO-GENERATED FILE: DO NOT EDIT\n")
d.write("#[feature(globs)];\n")
d.write("#[feature(globs, managed_boxes)];\n")
d.write("extern mod extra;\n")
d.write("extern mod run_pass_stage2;\n")
d.write("use run_pass_stage2::*;\n")

View File

@ -63,7 +63,7 @@ while cur < len(lines):
#[ allow(unused_variable) ];\n
#[ allow(dead_assignment) ];\n
#[ allow(unused_mut) ];\n
#[ feature(macro_rules, globs, struct_variant) ];\n
#[ feature(macro_rules, globs, struct_variant, managed_boxes) ];\n
""" + block
if xfail:
block = "// xfail-test\n" + block

View File

@ -33,7 +33,7 @@ Rust extras are part of the standard Rust distribution.
#[license = "MIT/ASL2"];
#[crate_type = "lib"];
#[feature(macro_rules, globs)];
#[feature(macro_rules, globs, managed_boxes)];
#[deny(non_camel_case_types)];
#[deny(missing_doc)];

View File

@ -138,8 +138,7 @@ impl Visitor<()> for Context {
experimental and likely to be removed");
},
// NOTE: enable after snapshot
ast::ty_box(_) if false => {
ast::ty_box(_) => {
self.gate_feature("managed_boxes", t.span, "The managed box syntax may be replaced \
by a library type, and a garbage \
collector is not yet implemented. \

View File

@ -17,7 +17,7 @@
#[license = "MIT/ASL2"];
#[crate_type = "lib"];
#[feature(macro_rules, globs, struct_variant)];
#[feature(macro_rules, globs, struct_variant, managed_boxes)];
// Rustc tasks always run on a fixed_stack_segment, so code in this
// module can call C functions (in particular, LLVM functions) with

View File

@ -17,7 +17,7 @@
#[license = "MIT/ASL2"];
#[crate_type = "lib"];
#[feature(globs, struct_variant)];
#[feature(globs, struct_variant, managed_boxes)];
extern mod syntax;
extern mod rustc;

View File

@ -18,7 +18,7 @@
#[license = "MIT/ASL2"];
#[crate_type = "lib"];
#[feature(globs)];
#[feature(globs, managed_boxes)];
extern mod extra;
extern mod rustc;

View File

@ -61,7 +61,7 @@ they contained the following prologue:
html_favicon_url = "http://www.rust-lang.org/favicon.ico",
html_root_url = "http://static.rust-lang.org/doc/master")];
#[feature(macro_rules, globs, asm)];
#[feature(macro_rules, globs, asm, managed_boxes)];
// Don't link to std. We are std.
#[no_std];

View File

@ -410,9 +410,7 @@ extern "rust-intrinsic" {
pub fn fabsf32(x: f32) -> f32;
pub fn fabsf64(x: f64) -> f64;
#[cfg(not(stage0))]
pub fn copysignf32(x: f32, y: f32) -> f32;
#[cfg(not(stage0))]
pub fn copysignf64(x: f64, y: f64) -> f64;
pub fn floorf32(x: f32) -> f32;
@ -424,19 +422,13 @@ extern "rust-intrinsic" {
pub fn truncf32(x: f32) -> f32;
pub fn truncf64(x: f64) -> f64;
#[cfg(not(stage0))]
pub fn rintf32(x: f32) -> f32;
#[cfg(not(stage0))]
pub fn rintf64(x: f64) -> f64;
#[cfg(not(stage0))]
pub fn nearbyintf32(x: f32) -> f32;
#[cfg(not(stage0))]
pub fn nearbyintf64(x: f64) -> f64;
#[cfg(not(stage0))]
pub fn roundf32(x: f32) -> f32;
#[cfg(not(stage0))]
pub fn roundf64(x: f64) -> f64;
pub fn ctpop8(x: i8) -> i8;

View File

@ -20,7 +20,7 @@
#[license = "MIT/ASL2"];
#[crate_type = "lib"];
#[feature(macro_rules, globs)];
#[feature(macro_rules, globs, managed_boxes)];
extern mod extra;

View File

@ -1,3 +1,11 @@
S 2013-10-22 ae0905a
freebsd-x86_64 6e9d81c160963308c2bf7886fae6726274b365ed
linux-i386 1c449504aa04c0345ad09f5bcb5a57b9656d11c3
linux-x86_64 ab649598e9af2ab3c38179e6229ea8cc4be6e338
macos-i386 28d4a2e8495a981e86e0c57fce05bcfc15ba656d
macos-x86_64 9506a3d746c1d1cc1befc5c9556f1653fee25f85
winnt-i386 6038235d3a2284beb7be8e80631ec6b6952df8ab
S 2013-10-21 6e6981c
freebsd-x86_64 7f630581d0e881483272140e84bc2f494daf6204
linux-i386 5c754455610013bbe448e8f6ef8ba1a05b167919

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
pub struct Entry<A,B> {
key: A,
value: B

View File

@ -8,6 +8,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
#[link(name = "crate_method_reexport_grrrrrrr2")];
pub use name_pool::add;

View File

@ -8,6 +8,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
#[link(name = "a", vers = "0.0")];
#[crate_type = "lib"];

View File

@ -8,6 +8,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
#[link(name = "req")];
#[crate_type = "lib"];

View File

@ -8,7 +8,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
/* -*- mode: rust; indent-tabs-mode: nil -*-
* Implementation of 'fasta' benchmark from

View File

@ -10,6 +10,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
extern mod extra;
use std::io::{ReaderUtil, WriterUtil};

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
extern mod extra;
use extra::list::{List, Cons, Nil};

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
struct clam {
x: @int,
y: @int,

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
fn main() {
struct A {
a: int,

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
struct foo(~int);
fn borrow(x: @mut foo) {

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
trait Foo {
fn borrowed<'a>(&'a self) -> &'a ();
}

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
trait Foo {
fn borrowed(&self);
fn borrowed_mut(&mut self);

View File

@ -1,3 +1,5 @@
#[feature(managed_boxes)];
fn f<T>(x: T) -> @T {
@x //~ ERROR value may contain borrowed pointers
}

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
trait T {
fn foo(@mut self);
}

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
trait noisy {
fn speak(&self);
}

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
type Foo = @[u8];
impl Drop for Foo { //~ ERROR the Drop trait may only be implemented

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
fn wants_box(x: @str) { }
fn wants_uniq(x: ~str) { }
fn wants_slice(x: &str) { }

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
fn wants_box(x: @[uint]) { }
fn wants_uniq(x: ~[uint]) { }
fn wants_three(x: [uint, ..3]) { }

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
fn takes_mut(x: @mut int) { }
fn takes_imm(x: @int) { }

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// test that autoderef of a type like this does not
// cause compiler to loop. Note that no instances
// of such a type could ever be constructed.

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// A test case for #2548.
struct foo {

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
struct P { child: Option<@mut P> }
trait PTrait {
fn getChildOption(&self) -> Option<@P>;

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// error-pattern: type `@Foo:'static` does not implement any method in scope named `foo`
trait Foo {

View File

@ -1,3 +1,5 @@
#[feature(managed_boxes)];
struct Foo {
f: @mut int,
}

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
fn foo(_x: @uint) {}
fn main() {

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
trait repeat<A> { fn get(&self) -> A; }
impl<A:Clone> repeat<A> for @A {

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
trait foo { fn foo(&self); }
fn to_foo<T:Clone + foo>(t: T) -> @foo {

View File

@ -8,6 +8,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
#[forbid(heap_memory)];
struct Foo {

View File

@ -8,6 +8,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
#[forbid(managed_heap_memory)];
struct Foo {

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
fn two_args<T>(x: T, y: T) { }
fn main() {

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
use std::container::Map;
use std::hashmap::HashMap;

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
use std::cell::Cell;
use std::task;

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// Test that an object type `@Foo` is not considered to implement the
// trait `Foo`. Issue #5087.

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
trait Foo {
fn borrowed(&self);
fn borrowed_mut(&mut self);

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
struct r {
i: @mut int,
}

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
struct point {
x: int,
y: int,

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
fn borrow<'r, T>(x: &'r T) -> &'r T {x}
fn foo(cond: &fn() -> bool, box: &fn() -> @int) {

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
struct invariant<'self> {
f: @mut &'self int
}

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
struct invariant<'self> {
f: @mut [&'self int]
}

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
struct invariant<'self> {
f: &'static fn(x: @mut &'self int)
}

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
struct invariant<'self> {
f: &'static fn() -> @mut &'self int
}

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
struct invariant<'self> {
f: @mut &'self int
}

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// Check that we correctly infer that b and c must be region
// parameterized because they reference a which requires a region.

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
struct ctxt { v: uint }
trait get_ctxt {

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
trait add {
fn plus(&self, x: Self) -> Self;
}

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
struct foo {
a: int,
b: int,

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// Tests for "default" bounds inferred for traits with no bounds list.
trait Foo {

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
trait Mumbo {
fn jumbo(&self, x: @uint) -> uint;
}

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
trait bar { fn dup(&self) -> Self; fn blah<X>(&self); }
impl bar for int { fn dup(&self) -> int { *self } fn blah<X>(&self) {} }
impl bar for uint { fn dup(&self) -> uint { *self } fn blah<X>(&self) {} }

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
struct r {
i: @mut int,
}

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// error-pattern:unreachable pattern
enum foo { a(@foo, int), b(uint), }

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// Test that a class with an unsendable field can't be
// sent

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// Gdb doesn't know about UTF-32 character encoding and will print a rust char as only
// its numerical value.

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// compile-flags:-Z extra-debug-info
// debugger:rbreak zzz
// debugger:run

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// compile-flags:-Z extra-debug-info
// debugger:rbreak zzz
// debugger:run

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// compile-flags:-Z extra-debug-info
// debugger:rbreak zzz
// debugger:run

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// compile-flags:-Z extra-debug-info
// debugger:rbreak zzz
// debugger:run

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// compile-flags:-Z extra-debug-info
// debugger:rbreak zzz
// debugger:run

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// compile-flags:-Z extra-debug-info
// debugger:set print pretty off
// debugger:rbreak zzz

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// compile-flags:-Z extra-debug-info
// debugger:set print pretty off
// debugger:rbreak zzz

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// compile-flags:-Z extra-debug-info
// debugger:run

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// error-pattern:meep
fn f(_a: int, _b: int, _c: @int) { fail!("moop"); }

View File

@ -1,3 +1,5 @@
#[feature(managed_boxes)];
// error-pattern:borrowed
trait Foo {

View File

@ -1,3 +1,5 @@
#[feature(managed_boxes)];
// error-pattern:borrowed
trait Foo {

View File

@ -1,3 +1,5 @@
#[feature(managed_boxes)];
// error-pattern:borrowed
// Test that write guards trigger when mut box is frozen

View File

@ -1,3 +1,5 @@
#[feature(managed_boxes)];
// error-pattern:borrowed
// Test that if you imm borrow then mut borrow it fails.

View File

@ -1,3 +1,5 @@
#[feature(managed_boxes)];
// error-pattern:borrowed
// Test that if you mut borrow then imm borrow it fails.

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// error-pattern:explicit failure
// Issue #2272 - unwind this without leaking the unique pointer

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// error-pattern:fail
fn failfn() {

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// error-pattern:fail
fn failfn() {

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// error-pattern:fail
fn f() -> @int { fail!(); }

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// error-pattern:fail
fn main() {

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// error-pattern:fail
fn main() {

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// error-pattern:fail
fn f(_a: @int) {
fail!();

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// error-pattern:squirrel
struct r {

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// error-pattern:quux
struct faily_box {

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// error-pattern:fail
fn fold_local() -> @~[int]{

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
// error-pattern:fail
fn fold_local() -> @~[int]{

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
struct pair<A,B> {
a: A, b: B
}

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
struct Pair<A,B> {
a: A, b: B
}

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
trait double {
fn double(@self) -> uint;
}

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
trait double {
fn double(self) -> uint;
}

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
trait double {
fn double(@self) -> uint;
}

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
trait Foo {
fn foo(&self) -> ~str;
}

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
use std::borrow;
use std::ptr;

View File

@ -10,6 +10,8 @@
// exec-env:RUST_POISON_ON_FREE=1
#[feature(managed_boxes)];
pub fn main() {
let x: @mut @Option<~int> = @mut @None;
match x {

View File

@ -10,6 +10,8 @@
// exec-env:RUST_POISON_ON_FREE=1
#[feature(managed_boxes)];
fn switcher(x: Option<@int>) {
let mut x = x;
match x {

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
struct F { f: @G }
struct G { g: ~[int] }

View File

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[feature(managed_boxes)];
fn borrow<'r,T>(x: &'r T) -> &'r T {x}
struct Rec { f: @int }

Some files were not shown because too many files have changed in this diff Show More