Closed
Description
Here is the error
main.rs:4:21: 4:26 error: internal compiler error: borrow-vec associated with bad sty: &ty_err
main.rs:4 let pie_slice = array.slice(1, 2);
^~~~~
note: the compiler hit an unexpected failure path. this is a bug.
note: we would appreciate a bug report: http://doc.rust-lang.org/complement-bugreport.html
note: run with `RUST_BACKTRACE=1` for a backtrace
task 'rustc' failed at 'Box<Any>', /home/rustbuild/src/rust-buildbot/slave/nightly-linux/build/src/libsyntax/diagnostic.rs:115
stack backtrace:
1: 0x7fde1a0f5620 - rt::backtrace::imp::write::h0fea79425673725266p
2: 0x7fde1a0f8e80 - failure::on_fail::h9aabe19bffc3104alsq
3: 0x7fde1a8bbff0 - unwind::begin_unwind_inner::h9b55d31cfec63a9e40d
4: 0x7fde18d72a90 - unwind::begin_unwind::h1183448402907672069
5: 0x7fde18d729c0 - diagnostic::SpanHandler::span_bug::h5b8de884ef10a1cbUdy
6: 0x7fde1ad239c0 - driver::session::Session::span_bug::hf691bf888bfdb422Znt
7: 0x7fde1ae92610 - middle::ty::adjust_ty::borrow_vec::h6f1dca784386e59eDZT
8: 0x7fde1ae8fa00 - middle::ty::adjust_ty::hcb1fa49e78b9b840LST
9: 0x7fde1af8b380 - middle::typeck::check::regionck::constrain_regions_in_type_of_node::h87665c249e125f57NWc
10: 0x7fde1af86050 - middle::typeck::check::regionck::visit_expr::h73423e7aa5968300D7b
11: 0x7fde1af8d470 - visit::walk_expr::h17493730021457087419
12: 0x7fde1af86050 - middle::typeck::check::regionck::visit_expr::h73423e7aa5968300D7b
13: 0x7fde1af8a160 - middle::typeck::check::regionck::visit_local::h763740eedaeb1379i4b
14: 0x7fde1af8a3d0 - visit::walk_block::h12723599008176341713
15: 0x7fde1afcee00 - middle::typeck::check::check_bare_fn::haf584d83c0be5c3bwBg
16: 0x7fde1afc7e60 - middle::typeck::check::check_item::h08679946a56c7e5fcah
17: 0x7fde1afcec00 - middle::typeck::check::check_item_types::hfa0d60d09ac306bcOAg
18: 0x7fde1b140a50 - middle::typeck::check_crate::h59523a23ed9761e6GhH
19: 0x7fde1b4c9d20 - driver::driver::phase_3_run_analysis_passes::h47669ed167b54bdezhs
20: 0x7fde1b4c55c0 - driver::driver::compile_input::h539bec547706263dA3r
21: 0x7fde1b57e050 - driver::run_compiler::h9cb91406a88d027059u
22: 0x7fde1b57df60 - driver::main_args::closure.$x22closure$x22$LP$133605$RP$
23: 0x7fde1b591ab0 - task::TaskBuilder<S>::try_future::closure.$x22closure$x22$LP$134754$RP$
24: 0x7fde1b591840 - task::TaskBuilder<S>::spawn_internal::closure.$x22closure$x22$LP$134731$RP$
25: 0x7fde1bf35df0 - task::spawn_opts::closure.$x22closure$x22$LP$8163$RP$
26: 0x7fde1a9137b0 - rust_try
27: 0x7fde1a8b9080 - unwind::try::hc59e8203d98cfea8tPd
28: 0x7fde1a8b8de0 - task::Task::run::hc5aad491de06c5bcP0c
29: 0x7fde1bf35be0 - task::spawn_opts::closure.$x22closure$x22$LP$8109$RP$
30: 0x7fde1a8bb060 - thread::thread_start::h597549996b7dcb76nnd
31: 0x7fde19b75060 - start_thread
32: 0x7fde1a583489 - __clone
33: 0x0 - <unknown>
Here is the code that generates the error
fn main()
{
let mut array = [1, 2, 3];
let pie_slice = array.slice(1, 2);
}
My system is x86_64 archlinux. The rust compiler version is
rustc -v
rustc 0.12.0-pre-nightly (afbcbbc77ffc6b10053bc543daf7d2e05d68cc01 2014-07-16 00:31:15 +0000)
Let me know if you guys need anything else.
(The code is really short so it shouldn't be hard to just type it in to duplicate the bug)