// -*- rust -*- type pair = rec(int head, mutable @mlist tail); type mlist = tag(cons(@pair), nil()); fn main() { let @pair p = rec(head=10, tail=mutable nil()); let @mlist cycle = cons(p); //p.tail = cycle; } // -*- rust -*- type cell = tup(mutable @list); type list = tag(link(@cell), nil()); fn main() { let @cell first = tup(@nil()); let @cell second = tup(@link(first)); first._0 = link(second); } // -*- rust -*- use std; type cell = tup(mutable @list); type list = tag(link(@cell), nil()); fn main() { let @cell first = tup(@nil()); let @cell second = tup(@link(first)); first._0 = link(second); std.sys.rustrt.gc(); let @cell third = tup(@nil()); } // -*- rust -*- use std; type cell = tup(mutable @list); type list = tag(link(@cell), nil()); fn main() { let @cell first = tup(@nil()); let @cell second = tup(@link(first)); first._0 = @link(second); std.sys.rustrt.gc(); let @cell third = tup(@nil()); } // -*- rust -*- use std; type cell = tup(mutable @list); type list = tag(link(@cell), nil()); fn main() { let @cell first = @tup(mutable @nil()); let @cell second = @tup(mutable @link(first)); first._0 = @link(second); std.sys.rustrt.gc(); let @cell third = @tup(mutable @nil()); } // -*- rust -*- use std; type cell = tup(mutable @list); tag list { link(@cell); nil(); } fn main() { let @cell first = @tup(mutable @nil()); let @cell second = @tup(mutable @link(first)); first._0 = @link(second); std.sys.rustrt.gc(); let @cell third = @tup(mutable @nil()); } // xfail-boot // xfail-stage0 // -*- rust -*- use std; type cell = tup(mutable @list); tag list { link(@cell); nil(); } fn main() { let @cell first = @tup(mutable @nil()); let @cell second = @tup(mutable @link(first)); first._0 = @link(second); std.sys.rustrt.gc(); let @cell third = @tup(mutable @nil()); } // xfail-boot // xfail-stage0 // xfail-stage1 // xfail-stage2 // -*- rust -*- use std; type cell = tup(mutable @list); tag list { link(@cell); nil(); } fn main() { let @cell first = @tup(mutable @nil()); let @cell second = @tup(mutable @link(first)); first._0 = @link(second); std.sys.rustrt.gc(); let @cell third = @tup(mutable @nil()); } // xfail-boot // xfail-stage0 // xfail-stage1 // xfail-stage2 // -*- rust -*- use std; type cell = tup(mutable @list); tag list { link(@cell); nil(); } fn main() { let @cell first = @tup(mutable @nil()); let @cell second = @tup(mutable @link(first)); first._0 = @link(second); std.Sys.rustrt.gc(); let @cell third = @tup(mutable @nil()); } // xfail-boot // xfail-stage0 // xfail-stage1 // xfail-stage2 // -*- rust -*- use std; type cell = tup(mutable @list); tag list { link(@cell); nil(); } fn main() { let @cell first = @tup(mutable @nil()); let @cell second = @tup(mutable @link(first)); first._0 = @link(second); std::sys.rustrt.gc(); let @cell third = @tup(mutable @nil()); } // xfail-stage0 // xfail-stage1 // xfail-stage2 // -*- rust -*- use std; type cell = tup(mutable @list); tag list { link(@cell); nil(); } fn main() { let @cell first = @tup(mutable @nil()); let @cell second = @tup(mutable @link(first)); first._0 = @link(second); std::sys.rustrt.gc(); let @cell third = @tup(mutable @nil()); } // xfail-stage0 // xfail-stage1 // xfail-stage2 // -*- rust -*- use std; type cell = tup(mutable @list); tag list { link(@cell); nil; } fn main() { let @cell first = @tup(mutable @nil()); let @cell second = @tup(mutable @link(first)); first._0 = @link(second); std::sys.rustrt.gc(); let @cell third = @tup(mutable @nil()); } // xfail-stage0 // xfail-stage1 // xfail-stage2 // xfail-stage3 // -*- rust -*- use std; type cell = tup(mutable @list); tag list { link(@cell); nil; } fn main() { let @cell first = @tup(mutable @nil()); let @cell second = @tup(mutable @link(first)); first._0 = @link(second); std::sys.rustrt.gc(); let @cell third = @tup(mutable @nil()); } // xfail-stage0 // xfail-stage1 // xfail-stage2 // xfail-stage3 // -*- rust -*- use std; type cell = rec(mutable @list c); tag list { link(@cell); nil; } fn main() { let @cell first = @rec(mutable c=@nil()); let @cell second = @rec(mutable c=@link(first)); first._0 = @link(second); std::sys.rustrt.gc(); let @cell third = @rec(mutable c=@nil()); } // xfail-stage0 // xfail-stage1 // xfail-stage2 // xfail-stage3 // -*- rust -*- use std; type cell = {mutable c: @list}; tag list { link(@cell); nil; } fn main() { let first: @cell = @{mutable c: @nil()}; let second: @cell = @{mutable c: @link(first)}; first._0 = @link(second); std::sys.rustrt.gc(); let third: @cell = @{mutable c: @nil()}; } // xfail-stage1 // xfail-stage2 // xfail-stage3 // -*- rust -*- use std; type cell = {mutable c: @list}; tag list { link(@cell); nil; } fn main() { let first: @cell = @{mutable c: @nil()}; let second: @cell = @{mutable c: @link(first)}; first._0 = @link(second); std::sys.rustrt.gc(); let third: @cell = @{mutable c: @nil()}; } // xfail-test // -*- rust -*- use std; type cell = {mutable c: @list}; tag list { link(@cell); nil; } fn main() { let first: @cell = @{mutable c: @nil()}; let second: @cell = @{mutable c: @link(first)}; first._0 = @link(second); std::sys.rustrt.gc(); let third: @cell = @{mutable c: @nil()}; } // xfail-stage1 // xfail-stage2 // xfail-stage3 // -*- rust -*- use std; type cell = {mutable c: @list}; tag list { link(@cell); nil; } fn main() { let first: @cell = @{mutable c: @nil()}; let second: @cell = @{mutable c: @link(first)}; first._0 = @link(second); std::sys.rustrt.gc(); let third: @cell = @{mutable c: @nil()}; } // xfail-test // -*- rust -*- use std; type cell = {mutable c: @list}; tag list { link(@cell); nil; } fn main() { let first: @cell = @{mutable c: @nil()}; let second: @cell = @{mutable c: @link(first)}; first._0 = @link(second); std::sys.rustrt.gc(); let third: @cell = @{mutable c: @nil()}; } // xfail-test // -*- rust -*- use std; type cell = {mutable c: @list}; tag list { link(@cell); nil; } fn main() { let first: @cell = @{mutable c: @nil()}; let second: @cell = @{mutable c: @link(first)}; first._0 = @link(second); sys.rustrt.gc(); let third: @cell = @{mutable c: @nil()}; } // xfail-test // -*- rust -*- use std; type cell = {mutable c: @list}; enum list { link(@cell); nil; } fn main() { let first: @cell = @{mutable c: @nil()}; let second: @cell = @{mutable c: @link(first)}; first._0 = @link(second); sys.rustrt.gc(); let third: @cell = @{mutable c: @nil()}; } // xfail-test // -*- rust -*- use std; type cell = {mutable c: @list}; enum list { link(@cell), nil, } fn main() { let first: @cell = @{mutable c: @nil()}; let second: @cell = @{mutable c: @link(first)}; first._0 = @link(second); sys.rustrt.gc(); let third: @cell = @{mutable c: @nil()}; } // xfail-test // -*- rust -*- use std; type cell = {mut c: @list}; enum list { link(@cell), nil, } fn main() { let first: @cell = @{mut c: @nil()}; let second: @cell = @{mut c: @link(first)}; first._0 = @link(second); sys.rustrt.gc(); let third: @cell = @{mut c: @nil()}; } // xfail-test // -*- rust -*- extern mod std; type cell = {mut c: @list}; enum list { link(@cell), nil, } fn main() { let first: @cell = @{mut c: @nil()}; let second: @cell = @{mut c: @link(first)}; first._0 = @link(second); sys.rustrt.gc(); let third: @cell = @{mut c: @nil()}; } // xfail-test // -*- rust -*- extern mod std; type Cell = {mut c: @List}; enum List { Link(@Cell), Nil, } fn main() { let first: @Cell = @{mut c: @Nil()}; let second: @Cell = @{mut c: @Link(first)}; first._0 = @Link(second); sys.rustrt.gc(); let third: @Cell = @{mut c: @Nil()}; } // xfail-test // -*- rust -*- extern mod std; type cell = {mut c: @list}; enum list { link(@cell), nil, } fn main() { let first: @cell = @{mut c: @nil()}; let second: @cell = @{mut c: @link(first)}; first._0 = @link(second); sys.rustrt.gc(); let third: @cell = @{mut c: @nil()}; } // 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 // -*- rust -*- extern mod std; type cell = {mut c: @list}; enum list { link(@cell), nil, } fn main() { let first: @cell = @{mut c: @nil()}; let second: @cell = @{mut c: @link(first)}; first._0 = @link(second); sys.rustrt.gc(); let third: @cell = @{mut c: @nil()}; } // 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 // -*- rust -*- extern mod std; type cell = {mut c: @list}; enum list { link(@cell), nil, } pub fn main() { let first: @cell = @{mut c: @nil()}; let second: @cell = @{mut c: @link(first)}; first._0 = @link(second); sys.rustrt.gc(); let third: @cell = @{mut c: @nil()}; } // 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 // -*- rust -*- extern mod std; type cell = {mut c: @list}; enum list { link(@cell), nil, } pub fn main() { let first: @cell = @{mut c: @nil()}; let second: @cell = @{mut c: @link(first)}; first._0 = @link(second); sys.rustrt.gc(); let third: @cell = @{mut c: @nil()}; } // 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 // -*- rust -*- extern mod std; type cell = {c: @list}; enum list { link(@mut cell), nil, } pub fn main() { let first: @cell = @mut {c: @nil()}; let second: @cell = @mut {c: @link(first)}; first._0 = @link(second); sys.rustrt.gc(); let third: @cell = @mut {c: @nil()}; } // 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 // -*- rust -*- extern mod core; use core::gc; use core::gc::rustrt; struct cell {c: @list} enum list { link(@mut cell), nil, } pub fn main() { let first: @cell = @mut cell{c: @nil()}; let second: @cell = @mut cell{c: @link(first)}; first._0 = @link(second); rustrt::gc(); let third: @cell = @mut cell{c: @nil()}; } // 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 // -*- rust -*- extern mod std; use std::gc; use std::gc::rustrt; struct cell {c: @list} enum list { link(@mut cell), nil, } pub fn main() { let first: @cell = @mut cell{c: @nil()}; let second: @cell = @mut cell{c: @link(first)}; first._0 = @link(second); rustrt::gc(); let third: @cell = @mut cell{c: @nil()}; } // 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; use std::gc; use std::gc::rustrt; struct cell {c: @list} enum list { link(@mut cell), nil, } pub fn main() { let first: @cell = @mut cell{c: @nil()}; let second: @cell = @mut cell{c: @link(first)}; first._0 = @link(second); rustrt::gc(); let third: @cell = @mut cell{c: @nil()}; }