Skip to content

ICE with task::try { fail!("failed") } #6854

Closed
@lilyball

Description

@lilyball

Compiling the following program:

fn main() {
    do std::task::try {
        fail!("failed");
    };
    println("try worked");
}

results in an ICE:

> env RUST_LOG=rustc1=,::rt::backtrace rustc foo.rs
rust: task failed at 'ty_fn_sig() called on non-fn type: &ty_err', /Users/kevin/Dev/rust/rust/src/librustc/middle/ty.rs:2803
error: internal compiler error: unexpected failure
note: the compiler hit an unexpected failure path. this is a bug
note: try running with RUST_LOG=rustc=1,::rt::backtrace to get further details and report the results to github.com/mozilla/rust/issues
rust: task failed at 'explicit failure', /Users/kevin/Dev/rust/rust/src/librustc/rustc.rc:400
rust: domain main @0x7f9983808410 root task failed

This is with current tip of incoming on OS X:

rustc 0.6 (237dce1 2013-05-30 17:22:49 -0700)
host: x86_64-apple-darwin

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions