Closed
Description
I can't show just a snippet of code to crash rustc but I made an special branch in my project with (what I think) is the minimum code required to crash rustc.
This is the full version of the code: ludat/lurri@2ec3223
This is the trimmed down version: ludat/lurri@f0536dd
I suspect that the culprit is the expansion of the piece
macro in the pattern matching in src/game.rs
in line 11
Also here is the travis build failing
I expected to see this happen: not to crash
Instead, this happened: crashed
Meta
rustc --version --verbose
:
rustc 1.3.0-nightly (be23d44a5 2015-07-20)
binary: rustc
commit-hash: be23d44a539deff16170d2af8fa10fb1cecc6a01
commit-date: 2015-07-20
host: x86_64-unknown-linux-gnu
release: 1.3.0-nightly
Backtrace:
Compiling lurri v0.1.0 (file:///home/lucas/Proyects/lurri)
thread 'rustc' panicked at 'called `Option::unwrap()` on a `None` value', ../src/libcore/option.rs:362
stack backtrace:
1: 0x7fbf73d06a8e - sys::backtrace::write::h6fc6daa5f5106581vus
2: 0x7fbf73d0ecb5 - panicking::on_panic::h2e630ece2d4363a7pgx
3: 0x7fbf73cd01ae - rt::unwind::begin_unwind_inner::h3b68e45f925e19e53Vw
4: 0x7fbf73cd0f06 - rt::unwind::begin_unwind_fmt::h9bdb324c84778b0b9Uw
5: 0x7fbf73d0e856 - rust_begin_unwind
6: 0x7fbf73d61124 - panicking::panic_fmt::h27a2c0209432b312ZeC
7: 0x7fbf73d5aedd - panicking::panic::h667023ec9fe87f2bwdC
8: 0x7fbf7346c2bd - check::_match::check_pat::h0d168aefbc0fec80C5a
9: 0x7fbf73482600 - check::_match::check_struct_pat_fields::h7c929bbf30c9b687gSb
10: 0x7fbf73480282 - check::_match::check_pat_struct::h41ddb16ab74ce8fc0Ab
11: 0x7fbf7346ab3f - check::_match::check_pat::h0d168aefbc0fec80C5a
12: 0x7fbf7348099a - check::_match::check_match::h9c69ab95d820ab93xvb
13: 0x7fbf7352348e - check::check_expr_with_unifier::h8132546069841091851
14: 0x7fbf734f89cb - check::check_block_with_expected::h7ab7a7c5f1768e05L0r
15: 0x7fbf734dc23a - check::check_fn::h4d1836a8819fd7bfPFn
16: 0x7fbf734f27c8 - check::check_bare_fn::hf12f7ee777ea52d1svn
17: 0x7fbf734f09c5 - check::check_item_body::h6a336ec58ce21a885Vn
18: 0x7fbf734f0ba2 - visit::walk_item::h197791554378392455
19: 0x7fbf734f23ff - check::check_item_types::hc3810fbdd30cdc45Zsn
20: 0x7fbf735afd5b - check_crate::haddd632d2e30ee4ffUC
21: 0x7fbf7426aa39 - driver::phase_3_run_analysis_passes::closure.16350
22: 0x7fbf7426937b - middle::ty::ctxt<'tcx>::create_and_enter::h4666070967497298580
23: 0x7fbf74264351 - driver::phase_3_run_analysis_passes::h15678580448791110156
24: 0x7fbf74248530 - driver::compile_input::h9f7bb33ca6460e8eTba
25: 0x7fbf7432b983 - run_compiler::h3baa6f4aa1c94d08A7b
26: 0x7fbf743293fe - boxed::F.FnBox<A>::call_box::h12363997576672449334
27: 0x7fbf74328d39 - rt::unwind::try::try_fn::h13342136736031437153
28: 0x7fbf73d89b08 - rust_try_inner
29: 0x7fbf73d89af5 - rust_try
30: 0x7fbf73cf9f17 - rt::unwind::try::inner_try::h39e7d773cdc65e57WRw
31: 0x7fbf74328f4b - boxed::F.FnBox<A>::call_box::h8760475721745798250
32: 0x7fbf73d0d8f1 - sys::thread::Thread::new::thread_start::h054a4d6de3e266d7J1v
33: 0x7fbf6d931353 - start_thread
34: 0x7fbf7396dbfc - __clone
35: 0x0 - <unknown>
Other: running Arch linux (up to date to 2015-07-27) using the rust-nightly-bin
package from the aur.