I am getting a Bus error - please see the following.Should I file this as
an issue in github?

amitava:learn amitava$ cat app.rs
// vi:ts=4:sw=4:nu

fn main() {
    // should not compile - infinite size, needs redirection
    struct Foo {
        child: Option<Foo>
    };

    let c = Foo {child: None};
    let p = Foo {child : Some(c) };
    //printfln!("%?", p);
}

amitava:learn amitava$ make
rustc -Z debug-info -o app app.rs
app.rs:10:5: 10:6 warning: unused variable: `p` [-W unused-variable
(default)]
app.rs:10     let p = Foo {child : Some(c) };
                  ^
make: *** [app] Bus error: 10

amitava:learn amitava$ rustc --version
rustc 0.8-pre (da96b3e 2013-08-28 14:15:37 -0700)
host: x86_64-apple-darwin

amitava:learn amitava$ uname -a
Darwin amitava.local 12.4.0 Darwin Kernel Version 12.4.0: Wed May  1
17:57:12 PDT 2013; root:xnu-2050.24.15~1/RELEASE_X86_64 x86_64

Thanks & Regards,
Amitava
_______________________________________________
Rust-dev mailing list
[email protected]
https://mail.mozilla.org/listinfo/rust-dev

Reply via email to