fn f(@rec(int a, int b) x) {
check (x.a == 10);
check (x.b == 12);
}
fn main() {
let @rec(int a, int b) z = rec(a=10, b=12);
let task p = spawn thread f(z);
join p;
}
// xfail-boot
// xfail-stage0
fn f(@rec(int a, int b) x) {
check (x.a == 10);
check (x.b == 12);
}
fn main() {
let @rec(int a, int b) z = rec(a=10, b=12);
let task p = spawn thread f(z);
join p;
}
// xfail-boot
// xfail-stage0
fn f(@rec(int a, int b) x) {
assert (x.a == 10);
assert (x.b == 12);
}
fn main() {
let @rec(int a, int b) z = rec(a=10, b=12);
let task p = spawn thread f(z);
join p;
}
// xfail-boot
// xfail-stage0
fn f(@rec(int a, int b) x) {
check (x.a == 10);
check (x.b == 12);
}
fn main() {
let @rec(int a, int b) z = rec(a=10, b=12);
let task p = spawn thread f(z);
join p;
}
// xfail-boot
// xfail-stage0
fn f(@rec(int a, int b) x) {
assert (x.a == 10);
assert (x.b == 12);
}
fn main() {
let @rec(int a, int b) z = rec(a=10, b=12);
let task p = spawn thread f(z);
join p;
}
// xfail-boot
// xfail-stage0
// xfail-stage1
// xfail-stage2
fn f(@rec(int a, int b) x) {
assert (x.a == 10);
assert (x.b == 12);
}
fn main() {
let @rec(int a, int b) z = rec(a=10, b=12);
let task p = spawn thread f(z);
join p;
}
// xfail-stage0
// xfail-stage1
// xfail-stage2
fn f(@rec(int a, int b) x) {
assert (x.a == 10);
assert (x.b == 12);
}
fn main() {
let @rec(int a, int b) z = rec(a=10, b=12);
let task p = spawn thread f(z);
join p;
}
// xfail-stage0
// xfail-stage1
// xfail-stage2
// xfail-stage3
fn f(@rec(int a, int b) x) {
assert (x.a == 10);
assert (x.b == 12);
}
fn main() {
let @rec(int a, int b) z = rec(a=10, b=12);
let task p = spawn thread f(z);
join p;
}
./src/test/run-pass/clone-with-exterior.rs:12:28:12:29: [1;31merror:[0m expecting (, found f
./src/test/run-pass/clone-with-exterior.rs:12 let task p = spawn thread f(z);
^
rt: ---
rt: f00e:main:main: upcall fail 'explicit failure', src/comp/syntax/parse/parser.rs:112
rt: f00e:main: domain main @0x8f2504c root task failed
// xfail-stage0
// xfail-stage1
// xfail-stage2
// xfail-stage3
fn f(@rec(int a, int b) x) {
assert (x.a == 10);
assert (x.b == 12);
}
fn main() {
let @rec(int a, int b) z = rec(a=10, b=12);
let task p = spawn thread f(z);
join p;
}
// xfail-stage1
// xfail-stage2
// xfail-stage3
fn f(@rec(int a, int b) x) {
assert (x.a == 10);
assert (x.b == 12);
}
fn main() {
let @rec(int a, int b) z = rec(a=10, b=12);
let task p = spawn thread f(z);
join p;
}
//xfail-stage0
//xfail-stage1
//xfail-stage2
//xfail-stage3
use std;
import std::task;
fn f(x : @{a:int, b:int}) {
assert (x.a == 10);
assert (x.b == 12);
}
fn main() {
let z : @{a:int, b:int} = @{ a : 10, b : 12};
let p = task::_spawn(bind f(z));
task::join_id(p);
}
//xfail-stage0
//xfail-test
use std;
import std::task;
fn f(x : @{a:int, b:int}) {
assert (x.a == 10);
assert (x.b == 12);
}
fn main() {
let z : @{a:int, b:int} = @{ a : 10, b : 12};
let p = task::_spawn(bind f(z));
task::join_id(p);
}
//xfail-stage0
//xfail-stage1
//xfail-stage2
//xfail-stage3
use std;
import std::task;
fn f(x : @{a:int, b:int}) {
assert (x.a == 10);
assert (x.b == 12);
}
fn main() {
let z : @{a:int, b:int} = @{ a : 10, b : 12};
let p = task::_spawn(bind f(z));
task::join_id(p);
}
//xfail-test
use std;
import std::task;
fn f(x : @{a:int, b:int}) {
assert (x.a == 10);
assert (x.b == 12);
}
fn main() {
let z : @{a:int, b:int} = @{ a : 10, b : 12};
let p = task::_spawn(bind f(z));
task::join_id(p);
}
//xfail-test
use std;
import task;
fn f(x : @{a:int, b:int}) {
assert (x.a == 10);
assert (x.b == 12);
}
fn main() {
let z : @{a:int, b:int} = @{ a : 10, b : 12};
let p = task::_spawn(bind f(z));
task::join_id(p);
}
//xfail-test
use std;
fn f(x : @{a:int, b:int}) {
assert (x.a == 10);
assert (x.b == 12);
}
fn main() {
let z : @{a:int, b:int} = @{ a : 10, b : 12};
let p = task::_spawn(bind f(z));
task::join_id(p);
}
//xfail-test
extern mod std;
fn f(x : @{a:int, b:int}) {
assert (x.a == 10);
assert (x.b == 12);
}
fn main() {
let z : @{a:int, b:int} = @{ a : 10, b : 12};
let p = task::_spawn(bind f(z));
task::join_id(p);
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
//xfail-test
extern mod std;
fn f(x : @{a:int, b:int}) {
assert (x.a == 10);
assert (x.b == 12);
}
fn main() {
let z : @{a:int, b:int} = @{ a : 10, b : 12};
let p = task::_spawn(bind f(z));
task::join_id(p);
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
//xfail-test
extern mod std;
fn f(x : @{a:int, b:int}) {
assert (x.a == 10);
assert (x.b == 12);
}
pub fn main() {
let z : @{a:int, b:int} = @{ a : 10, b : 12};
let p = task::_spawn(bind f(z));
task::join_id(p);
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
//xfail-test
extern mod std;
fn f(x : @{a:int, b:int}) {
assert (x.a == 10);
assert (x.b == 12);
}
pub fn main() {
let z : @{a:int, b:int} = @{ a : 10, b : 12};
let p = task::_spawn(bind f(z));
task::join_id(p);
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
//xfail-test
extern mod std;
fn f(x : @{a:int, b:int}) {
fail_unless!((x.a == 10));
fail_unless!((x.b == 12));
}
pub fn main() {
let z : @{a:int, b:int} = @{ a : 10, b : 12};
let p = task::_spawn(bind f(z));
task::join_id(p);
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
//xfail-test
extern mod std;
fn f(x : @{a:int, b:int}) {
assert!((x.a == 10));
assert!((x.b == 12));
}
pub fn main() {
let z : @{a:int, b:int} = @{ a : 10, b : 12};
let p = task::_spawn(bind f(z));
task::join_id(p);
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
extern mod std;
use core::task::spawn;
struct Pair {
a: int,
b: int
}
pub fn main() {
let z = ~Pair { a : 10, b : 12};
let f: ~fn() = || {
assert!((z.a == 10));
assert!((z.b == 12));
};
spawn(f);
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
extern mod std;
use core::task::spawn;
struct Pair {
a: int,
b: int
}
pub fn main() {
let z = ~Pair { a : 10, b : 12};
let f: ~fn() = || {
assert!((z.a == 10));
assert!((z.b == 12));
};
spawn(f);
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
extern mod std;
use core::task::spawn;
struct Pair {
a: int,
b: int
}
pub fn main() {
let z = ~Pair { a : 10, b : 12};
let f: ~fn() = || {
assert_eq!(z.a, 10);
assert_eq!(z.b, 12);
};
spawn(f);
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
extern mod extra;
use std::task::spawn;
struct Pair {
a: int,
b: int
}
pub fn main() {
let z = ~Pair { a : 10, b : 12};
let f: ~fn() = || {
assert_eq!(z.a, 10);
assert_eq!(z.b, 12);
};
spawn(f);
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
extern mod extra;
use std::task::spawn;
struct Pair {
a: int,
b: int
}
pub fn main() {
let z = ~Pair { a : 10, b : 12};
let f: proc() = || {
assert_eq!(z.a, 10);
assert_eq!(z.b, 12);
};
spawn(f);
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
extern mod extra;
use std::task::spawn;
struct Pair {
a: int,
b: int
}
pub fn main() {
let z = ~Pair { a : 10, b : 12};
let f: proc() = proc() {
assert_eq!(z.a, 10);
assert_eq!(z.b, 12);
};
spawn(f);
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
extern crate extra;
use std::task::spawn;
struct Pair {
a: int,
b: int
}
pub fn main() {
let z = ~Pair { a : 10, b : 12};
let f: proc() = proc() {
assert_eq!(z.a, 10);
assert_eq!(z.b, 12);
};
spawn(f);
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
use std::task::spawn;
struct Pair {
a: int,
b: int
}
pub fn main() {
let z = ~Pair { a : 10, b : 12};
let f: proc() = proc() {
assert_eq!(z.a, 10);
assert_eq!(z.b, 12);
};
spawn(f);
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
use std::task::spawn;
struct Pair {
a: int,
b: int
}
pub fn main() {
let z = ~Pair { a : 10, b : 12};
let f: proc:Send() = proc() {
assert_eq!(z.a, 10);
assert_eq!(z.b, 12);
};
spawn(f);
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
use std::task::spawn;
struct Pair {
a: int,
b: int
}
pub fn main() {
let z = ~Pair { a : 10, b : 12};
let f: proc():Send = proc() {
assert_eq!(z.a, 10);
assert_eq!(z.b, 12);
};
spawn(f);
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
use std::task::spawn;
struct Pair {
a: int,
b: int
}
pub fn main() {
let z = box Pair { a : 10, b : 12};
let f: proc():Send = proc() {
assert_eq!(z.a, 10);
assert_eq!(z.b, 12);
};
spawn(f);
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
use std::task::spawn;
struct Pair {
a: int,
b: int
}
pub fn main() {
let z = box Pair { a : 10, b : 12};
spawn(move|| {
assert_eq!(z.a, 10);
assert_eq!(z.b, 12);
});
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
use std::thread::Thread;
struct Pair {
a: int,
b: int
}
pub fn main() {
let z = box Pair { a : 10, b : 12};
let _t = Thread::spawn(move|| {
assert_eq!(z.a, 10);
assert_eq!(z.b, 12);
});
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![allow(unknown_features)]
#![feature(box_syntax)]
use std::thread::Thread;
struct Pair {
a: int,
b: int
}
pub fn main() {
let z = box Pair { a : 10, b : 12};
let _t = Thread::spawn(move|| {
assert_eq!(z.a, 10);
assert_eq!(z.b, 12);
});
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![allow(unknown_features)]
#![feature(box_syntax)]
use std::thread::Thread;
struct Pair {
a: int,
b: int
}
pub fn main() {
let z: Box<_> = box Pair { a : 10, b : 12};
let _t = Thread::spawn(move|| {
assert_eq!(z.a, 10);
assert_eq!(z.b, 12);
});
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![allow(unknown_features)]
#![feature(box_syntax, std_misc)]
use std::thread::Thread;
struct Pair {
a: int,
b: int
}
pub fn main() {
let z: Box<_> = box Pair { a : 10, b : 12};
let _t = Thread::spawn(move|| {
assert_eq!(z.a, 10);
assert_eq!(z.b, 12);
});
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
// pretty-expanded FIXME #23616
#![allow(unknown_features)]
#![feature(box_syntax, std_misc)]
use std::thread::Thread;
struct Pair {
a: int,
b: int
}
pub fn main() {
let z: Box<_> = box Pair { a : 10, b : 12};
let _t = Thread::spawn(move|| {
assert_eq!(z.a, 10);
assert_eq!(z.b, 12);
});
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
// pretty-expanded FIXME #23616
#![allow(unknown_features)]
#![feature(box_syntax, std_misc)]
use std::thread::Thread;
struct Pair {
a: isize,
b: isize
}
pub fn main() {
let z: Box<_> = box Pair { a : 10, b : 12};
let _t = Thread::spawn(move|| {
assert_eq!(z.a, 10);
assert_eq!(z.b, 12);
});
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
// pretty-expanded FIXME #23616
#![allow(unknown_features)]
#![feature(box_syntax, std_misc)]
use std::thread;
struct Pair {
a: isize,
b: isize
}
pub fn main() {
let z: Box<_> = box Pair { a : 10, b : 12};
let _t = thread::scoped(move|| {
assert_eq!(z.a, 10);
assert_eq!(z.b, 12);
});
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![allow(unknown_features)]
#![feature(box_syntax, std_misc)]
use std::thread;
struct Pair {
a: isize,
b: isize
}
pub fn main() {
let z: Box<_> = box Pair { a : 10, b : 12};
let _t = thread::scoped(move|| {
assert_eq!(z.a, 10);
assert_eq!(z.b, 12);
});
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
// pretty-expanded FIXME #23616
#![allow(unknown_features)]
#![feature(box_syntax, std_misc)]
use std::thread;
struct Pair {
a: isize,
b: isize
}
pub fn main() {
let z: Box<_> = box Pair { a : 10, b : 12};
thread::spawn(move|| {
assert_eq!(z.a, 10);
assert_eq!(z.b, 12);
}).join();
}
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![allow(unknown_features)]
#![feature(box_syntax, std_misc)]
use std::thread;
struct Pair {
a: isize,
b: isize
}
pub fn main() {
let z: Box<_> = box Pair { a : 10, b : 12};
thread::spawn(move|| {
assert_eq!(z.a, 10);
assert_eq!(z.b, 12);
}).join();
}