Skip to content

Index out of bounds panic in InferCtxt::shallow_resolve #24152

Closed
@kvark

Description

@kvark

Rust:

rustc 1.0.0-nightly (f207ecb 2015-04-03) (built 2015-04-04)

System:

Linux mezon 3.19.2-1-ARCH #1 SMP PREEMPT Wed Mar 18 16:21:02 CET 2015 x86_64 GNU/Linux

Call stack:

examples/viewer.rs:89:20: 89:53 error: type `gfx_scene::Camera<cgmath::projection::PerspectiveFov<f32, cgmath::angle::Rad<f32>>, id::Id<claymore_scene::space::Node<cgmath::transform::Decomposed<f32, cgmath::vector::Vector3<f32>, cgmath::quaternion::Quaternion<f32>>>>>` does not implement any method in scope named `get_view_projection`
examples/viewer.rs:89             camera.get_view_projection(&scene.world));
                                         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
error: internal compiler error: unexpected panic
note: the compiler unexpectedly panicked. this is a bug.
note: we would appreciate a bug report: https://github.com/rust-lang/rust/blob/master/CONTRIBUTING.md#bug-reports
note: run with `RUST_BACKTRACE=1` for a backtrace
thread 'rustc' panicked at 'index out of bounds: the len is 466 but the index is 468', /home/rustbuild/src/rust-buildbot/slave/nightly-dist-rustc-linux/build/src/libcollections/vec.rs:1347

stack backtrace:
   1:     0x7f248094e708 - sys::backtrace::write::he3059e6bc8c10ccbZGC
   2:     0x7f2480979ad7 - panicking::on_panic::h4b318d56839ed7af9TI
   3:     0x7f24808b17e3 - rt::unwind::begin_unwind_inner::hbbbefb3640cc608bhzI
   4:     0x7f24808b1bcf - rt::unwind::begin_unwind_fmt::ha9be29259324c678VxI
   5:     0x7f24809796b7 - rust_begin_unwind
   6:     0x7f24809cced4 - panicking::panic_fmt::h207b454d96d05fa55jC
   7:     0x7f24809d8acc - panicking::panic_bounds_check::hc8342fa18a8e9a7abjC
   8:     0x7f247e7c4c4c - middle::infer::InferCtxt<'a, 'tcx>::shallow_resolve::h8d9901209ee37252aEz
   9:     0x7f247e77cf28 - middle::infer::resolve::OpportunisticTypeResolver<'a, 'tcx>.ty_fold..TypeFolder<'tcx>::fold_ty::hf81f20499d301ebahdx
  10:     0x7f247e77dad2 - middle::ty_fold::TypeFolder::fold_substs::h13937777481293698873
  11:     0x7f247e8653d0 - middle::traits::project::project_type::h99741ff3ebe80d42YtP
  12:     0x7f247e863a71 - middle::traits::project::opt_normalize_projection_type::h32da6b6dc6469563AmP
  13:     0x7f247e85db1a - middle::traits::project::poly_project_and_unify_type::closure.83578
  14:     0x7f247e85b9cc - middle::traits::project::poly_project_and_unify_type::h6f123691465a78bbJ2O
  15:     0x7f247e85263b - middle::traits::fulfill::FulfillmentContext<'tcx>::select::hed41f9cbe55449c9SEO
  16:     0x7f247e8521de - middle::traits::fulfill::FulfillmentContext<'tcx>::select_new_obligations::h0d7f754d8c571f0bxDO
  17:     0x7f247f5b6a88 - check::vtable::select_new_fcx_obligations::h8531397917539799I4b
  18:     0x7f247f65cd37 - check::check_argument_types::ha74fa599001195e8dbq
  19:     0x7f247f65ecf0 - check::check_method_argument_types::h891da6cdf031e251C8p
  20:     0x7f247f692b15 - check::check_expr_with_unifier::check_method_call::h079a9db8d22ba142CKq
  21:     0x7f247f686b60 - check::check_expr_with_unifier::h10870247092722481391
  22:     0x7f247f65cf98 - check::check_argument_types::ha74fa599001195e8dbq
  23:     0x7f247f65ec0a - check::check_method_argument_types::h891da6cdf031e251C8p
  24:     0x7f247f692b15 - check::check_expr_with_unifier::check_method_call::h079a9db8d22ba142CKq
  25:     0x7f247f6c67ff - check::check_expr_with_unifier::h2466168795244030596
  26:     0x7f247f6765d3 - check::check_block_with_expected::h37d9c01d948e7c26Qns
  27:     0x7f247f691894 - check::check_block_no_value::h6d9b43475a55f2baRms
  28:     0x7f247f6a566d - check::check_expr_with_unifier::h1128841108473440828
  29:     0x7f247f67654e - check::check_block_with_expected::h37d9c01d948e7c26Qns
  30:     0x7f247f653e19 - check::check_fn::hf224b26834f6985dWZn
  31:     0x7f247f67150c - check::check_bare_fn::h3bd8f9ddb42906aevPn
  32:     0x7f247f66b3d4 - check::check_item::h9d147ebfae788c9cg8n
  33:     0x7f247f742ec6 - check_crate::closure.36252
  34:     0x7f247f73d413 - check_crate::hf86b00a9a711df871oC
  35:     0x7f2480fce5ad - driver::phase_3_run_analysis_passes::h7afb182e7d24bba2gGa
  36:     0x7f2480fb2405 - driver::compile_input::hd7743659db68d680Qba
  37:     0x7f2481069875 - run_compiler::h8e4dca3e7b3dd900S4b
  38:     0x7f248106718d - boxed::F.FnBox<A>::call_box::h4911342064246001069
  39:     0x7f24810666c9 - rt::unwind::try::try_fn::h1593779289253196900
  40:     0x7f24809f6288 - rust_try_inner
  41:     0x7f24809f6275 - rust_try
  42:     0x7f248106699b - boxed::F.FnBox<A>::call_box::h13493051407817611035
  43:     0x7f2480964ac1 - sys::thread::create::thread_start::hf5d11b227fd9319cruH
  44:     0x7f247a759373 - start_thread
  45:     0x7f248052427c - __clone
  46:                0x0 - <unknown>

Could not compile `claymore`.

Metadata

Metadata

Assignees

No one assigned

    Labels

    I-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions