You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fn memFib(n: int) -> int {
let memo = [0, 1];
let fib = |n: int| -> int {
match memo.len() as int {
0 .. n - 1 => memo[n],
_ => memFib(n - 1) + memFib(n - 2)
}
};
}
fn main() {
io::println(fmt!("%d", memFib(7)));
}
$ RUST_LOG=rustc=1,::rt::backtrace rust run Fail.rs
rust: task failed at 'Bad operands for binary', /Users/nils/Develop/rust-0.6/src/librustc/middle/const_eval.rs:251
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/nils/Develop/rust-0.6/src/librustc/rustc.rc:357
rust: domain main @0x7fa4d900c210 root task failed
The text was updated successfully, but these errors were encountered:
$ RUST_LOG=rustc=1,::rt::backtrace rust run Fail.rs
rust: task failed at 'Bad operands for binary', /Users/nils/Develop/rust-0.6/src/librustc/middle/const_eval.rs:251
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/nils/Develop/rust-0.6/src/librustc/rustc.rc:357
rust: domain main @0x7fa4d900c210 root task failed
The text was updated successfully, but these errors were encountered: