<p dir="auto">I don't really know what could be causing this bug, but this code</p>
<div class="highlight highlight-source-rust notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="struct Test;

impl Add&lt;i32, i32&gt; for Test {
    fn add(&amp;self, othr: &amp;i32) -&gt; i32 {
        othr + 1
    }
}

impl Add&lt;f64, f64&gt; for Test {
    fn add(&amp;self, othr: &amp;f64) -&gt; f64 {
        othr + 2.0
    }
}

fn main() {
    let f = Test;
    println!(&quot;f + 3:   {}&quot;, f + 3);
    println!(&quot;f + 3.0: {}&quot;, f + 3.0);
}"><pre class="notranslate"><span class="pl-k">struct</span> <span class="pl-smi">Test</span><span class="pl-kos">;</span>

<span class="pl-k">impl</span> <span class="pl-smi">Add</span><span class="pl-kos">&lt;</span><span class="pl-smi">i32</span><span class="pl-kos">,</span> <span class="pl-smi">i32</span><span class="pl-kos">&gt;</span> <span class="pl-k">for</span> <span class="pl-smi">Test</span> <span class="pl-kos">{</span>
    <span class="pl-k">fn</span> <span class="pl-en">add</span><span class="pl-kos">(</span><span class="pl-c1">&amp;</span><span class="pl-smi">self</span><span class="pl-kos">,</span> <span class="pl-s1">othr</span><span class="pl-kos">:</span> <span class="pl-c1">&amp;</span><span class="pl-smi">i32</span><span class="pl-kos">)</span> -&gt; <span class="pl-smi">i32</span> <span class="pl-kos">{</span>
        othr + <span class="pl-c1">1</span>
    <span class="pl-kos">}</span>
<span class="pl-kos">}</span>

<span class="pl-k">impl</span> <span class="pl-smi">Add</span><span class="pl-kos">&lt;</span><span class="pl-smi">f64</span><span class="pl-kos">,</span> <span class="pl-smi">f64</span><span class="pl-kos">&gt;</span> <span class="pl-k">for</span> <span class="pl-smi">Test</span> <span class="pl-kos">{</span>
    <span class="pl-k">fn</span> <span class="pl-en">add</span><span class="pl-kos">(</span><span class="pl-c1">&amp;</span><span class="pl-smi">self</span><span class="pl-kos">,</span> <span class="pl-s1">othr</span><span class="pl-kos">:</span> <span class="pl-c1">&amp;</span><span class="pl-smi">f64</span><span class="pl-kos">)</span> -&gt; <span class="pl-smi">f64</span> <span class="pl-kos">{</span>
        othr + <span class="pl-c1">2.0</span>
    <span class="pl-kos">}</span>
<span class="pl-kos">}</span>

<span class="pl-k">fn</span> <span class="pl-en">main</span><span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-kos">{</span>
    <span class="pl-k">let</span> f = <span class="pl-v">Test</span><span class="pl-kos">;</span>
    <span class="pl-en">println</span><span class="pl-en">!</span><span class="pl-kos">(</span><span class="pl-s">"f + 3:   {}"</span>, f + <span class="pl-c1">3</span><span class="pl-kos">)</span><span class="pl-kos">;</span>
    <span class="pl-en">println</span><span class="pl-en">!</span><span class="pl-kos">(</span><span class="pl-s">"f + 3.0: {}"</span>, f + <span class="pl-c1">3.0</span><span class="pl-kos">)</span><span class="pl-kos">;</span>
<span class="pl-kos">}</span></pre></div>
<p dir="auto">using this version of rustc,</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="rustc 0.13.0-nightly (0a5e7f359 2014-11-03 23:16:55 +0000)
binary: rustc
commit-hash: 0a5e7f35949d18f312dca90af73e56aced6f2b0e
commit-date: 2014-11-03 23:16:55 +0000
host: x86_64-apple-darwin
release: 0.13.0-nightly"><pre class="notranslate"><code class="notranslate">rustc 0.13.0-nightly (0a5e7f359 2014-11-03 23:16:55 +0000)
binary: rustc
commit-hash: 0a5e7f35949d18f312dca90af73e56aced6f2b0e
commit-date: 2014-11-03 23:16:55 +0000
host: x86_64-apple-darwin
release: 0.13.0-nightly
</code></pre></div>
<p dir="auto">on Mac OS X 10.10<br>
causes</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="[tyler@mac ~]$ RUST_BACKTRACE=1 rustc test.rs
error: internal compiler error: Impl DefId { krate: 0, node: 7 }:Test.Add&lt;i32, i32&gt; was matchable against Obligation(trait_ref=&lt;_ as core::ops::Add&lt;_, _&gt;&gt;,depth=0) but now is not
note: the compiler unexpectedly panicked. 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' panicked at 'Box&lt;Any&gt;', /Users/rustbuild/src/rust-buildbot/slave/nightly-mac/build/src/libsyntax/diagnostic.rs:175

stack backtrace:
   1:        0x10a2997ff - rt::backtrace::imp::write::h41ac48e0092ef821Kqq
   2:        0x10a29c987 - failure::on_fail::h3381510cd10c9a61zHq
   3:        0x10a4f5495 - unwind::begin_unwind_inner::h8667451db5084e88EKd
   4:        0x109a88897 - unwind::begin_unwind::h574859237947728247
   5:        0x109a890d3 - diagnostic::Handler::bug::h6b8e7fd2f9430272TgG
   6:        0x10733a9c1 - middle::traits::select::SelectionContext&lt;'cx, 'tcx&gt;::rematch_impl::h88c48df6dbcc8ecfbkZ
   7:        0x1073294ab - middle::traits::select::SelectionContext&lt;'cx, 'tcx&gt;::confirm_candidate::h66ce271d2e7c254er0Y
   8:        0x107321837 - middle::traits::select::SelectionContext&lt;'cx, 'tcx&gt;::select::h1fe5e22ffd93df8bVuX
   9:        0x107320746 - middle::traits::fulfill::FulfillmentContext::select::hb3fa38b300468ae1f2W
  10:        0x10731ffbc - middle::traits::fulfill::FulfillmentContext::select_where_possible::hc2e2275050ef1b1eu1W
  11:        0x107235782 - middle::traits::fulfill::FulfillmentContext::select_all_or_error::h5af4c7aa23325766hZW
  12:        0x1074a1638 - middle::typeck::check::vtable::select_all_fcx_obligations_or_error::h2aa8ac2036bfa6468aO
  13:        0x1074f679b - middle::typeck::check::check_bare_fn::heec9ab1513e561178IV
  14:        0x1074f25dd - middle::typeck::check::check_item::h88a198c1ca5a907bh3V
  15:        0x1074f65df - middle::typeck::check::check_item_types::h153b2b615101bfcaiIV
  16:        0x106ffcbc6 - util::common::time::h7711944396490138833
  17:        0x1077bd73e - middle::typeck::check_crate::hd52e86e35ee1a30a3uo
  18:        0x10782696f - driver::driver::phase_3_run_analysis_passes::h340df4cdb996da5a8hB
  19:        0x107821198 - driver::driver::compile_input::h02967bf5608361a5TYA
  20:        0x10789fd3c - driver::run_compiler::h3ec9fe79d927cfd96OE
  21:        0x10789e1ce - driver::run::closure.145814
  22:        0x10701552b - task::TaskBuilder&lt;S&gt;::try_future::closure.104091
  23:        0x107015423 - task::TaskBuilder&lt;S&gt;::spawn_internal::closure.104062
  24:        0x106f93c7d - task::NativeSpawner.Spawner::spawn::closure.8516
  25:        0x10a55468c - rust_try_inner
  26:        0x10a554676 - rust_try
  27:        0x10a4f2c67 - unwind::try::h7be47cb819f03817Yyd
  28:        0x10a4f2afc - task::Task::run::hd977e1132c48b8d6LKc
  29:        0x106f93aa3 - task::NativeSpawner.Spawner::spawn::closure.8453
  30:        0x10a4f4327 - thread::thread_start::ha9ae96309fe3363b05c
  31:     0x7fff8c73d2fc - _pthread_body
  32:     0x7fff8c73d279 - _pthread_body"><pre class="notranslate"><code class="notranslate">[tyler@mac ~]$ RUST_BACKTRACE=1 rustc test.rs
error: internal compiler error: Impl DefId { krate: 0, node: 7 }:Test.Add&lt;i32, i32&gt; was matchable against Obligation(trait_ref=&lt;_ as core::ops::Add&lt;_, _&gt;&gt;,depth=0) but now is not
note: the compiler unexpectedly panicked. 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' panicked at 'Box&lt;Any&gt;', /Users/rustbuild/src/rust-buildbot/slave/nightly-mac/build/src/libsyntax/diagnostic.rs:175

stack backtrace:
   1:        0x10a2997ff - rt::backtrace::imp::write::h41ac48e0092ef821Kqq
   2:        0x10a29c987 - failure::on_fail::h3381510cd10c9a61zHq
   3:        0x10a4f5495 - unwind::begin_unwind_inner::h8667451db5084e88EKd
   4:        0x109a88897 - unwind::begin_unwind::h574859237947728247
   5:        0x109a890d3 - diagnostic::Handler::bug::h6b8e7fd2f9430272TgG
   6:        0x10733a9c1 - middle::traits::select::SelectionContext&lt;'cx, 'tcx&gt;::rematch_impl::h88c48df6dbcc8ecfbkZ
   7:        0x1073294ab - middle::traits::select::SelectionContext&lt;'cx, 'tcx&gt;::confirm_candidate::h66ce271d2e7c254er0Y
   8:        0x107321837 - middle::traits::select::SelectionContext&lt;'cx, 'tcx&gt;::select::h1fe5e22ffd93df8bVuX
   9:        0x107320746 - middle::traits::fulfill::FulfillmentContext::select::hb3fa38b300468ae1f2W
  10:        0x10731ffbc - middle::traits::fulfill::FulfillmentContext::select_where_possible::hc2e2275050ef1b1eu1W
  11:        0x107235782 - middle::traits::fulfill::FulfillmentContext::select_all_or_error::h5af4c7aa23325766hZW
  12:        0x1074a1638 - middle::typeck::check::vtable::select_all_fcx_obligations_or_error::h2aa8ac2036bfa6468aO
  13:        0x1074f679b - middle::typeck::check::check_bare_fn::heec9ab1513e561178IV
  14:        0x1074f25dd - middle::typeck::check::check_item::h88a198c1ca5a907bh3V
  15:        0x1074f65df - middle::typeck::check::check_item_types::h153b2b615101bfcaiIV
  16:        0x106ffcbc6 - util::common::time::h7711944396490138833
  17:        0x1077bd73e - middle::typeck::check_crate::hd52e86e35ee1a30a3uo
  18:        0x10782696f - driver::driver::phase_3_run_analysis_passes::h340df4cdb996da5a8hB
  19:        0x107821198 - driver::driver::compile_input::h02967bf5608361a5TYA
  20:        0x10789fd3c - driver::run_compiler::h3ec9fe79d927cfd96OE
  21:        0x10789e1ce - driver::run::closure.145814
  22:        0x10701552b - task::TaskBuilder&lt;S&gt;::try_future::closure.104091
  23:        0x107015423 - task::TaskBuilder&lt;S&gt;::spawn_internal::closure.104062
  24:        0x106f93c7d - task::NativeSpawner.Spawner::spawn::closure.8516
  25:        0x10a55468c - rust_try_inner
  26:        0x10a554676 - rust_try
  27:        0x10a4f2c67 - unwind::try::h7be47cb819f03817Yyd
  28:        0x10a4f2afc - task::Task::run::hd977e1132c48b8d6LKc
  29:        0x106f93aa3 - task::NativeSpawner.Spawner::spawn::closure.8453
  30:        0x10a4f4327 - thread::thread_start::ha9ae96309fe3363b05c
  31:     0x7fff8c73d2fc - _pthread_body
  32:     0x7fff8c73d279 - _pthread_body
</code></pre></div>
<p dir="auto">Apologies if this is an incorrect format or non-relevant, I've never really submitted a bug report to a large project before.</p>
<p dir="auto">Addendum:<br>
Adding "f64" to the second println!:</p>
<div class="highlight highlight-source-rust notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="struct Test;

impl Add&lt;i32, i32&gt; for Test {
    fn add(&amp;self, othr: &amp;i32) -&gt; i32 {
        othr + 1
    }
}

impl Add&lt;f64, f64&gt; for Test {
    fn add(&amp;self, othr: &amp;f64) -&gt; f64 {
        othr + 2.0
    }
}

fn main() {
    let f = Test;
    println!(&quot;f + 3:   {}&quot;, f + 3);
    println!(&quot;f + 3.0: {}&quot;, f + 3.0f64);
}"><pre class="notranslate"><span class="pl-k">struct</span> <span class="pl-smi">Test</span><span class="pl-kos">;</span>

<span class="pl-k">impl</span> <span class="pl-smi">Add</span><span class="pl-kos">&lt;</span><span class="pl-smi">i32</span><span class="pl-kos">,</span> <span class="pl-smi">i32</span><span class="pl-kos">&gt;</span> <span class="pl-k">for</span> <span class="pl-smi">Test</span> <span class="pl-kos">{</span>
    <span class="pl-k">fn</span> <span class="pl-en">add</span><span class="pl-kos">(</span><span class="pl-c1">&amp;</span><span class="pl-smi">self</span><span class="pl-kos">,</span> <span class="pl-s1">othr</span><span class="pl-kos">:</span> <span class="pl-c1">&amp;</span><span class="pl-smi">i32</span><span class="pl-kos">)</span> -&gt; <span class="pl-smi">i32</span> <span class="pl-kos">{</span>
        othr + <span class="pl-c1">1</span>
    <span class="pl-kos">}</span>
<span class="pl-kos">}</span>

<span class="pl-k">impl</span> <span class="pl-smi">Add</span><span class="pl-kos">&lt;</span><span class="pl-smi">f64</span><span class="pl-kos">,</span> <span class="pl-smi">f64</span><span class="pl-kos">&gt;</span> <span class="pl-k">for</span> <span class="pl-smi">Test</span> <span class="pl-kos">{</span>
    <span class="pl-k">fn</span> <span class="pl-en">add</span><span class="pl-kos">(</span><span class="pl-c1">&amp;</span><span class="pl-smi">self</span><span class="pl-kos">,</span> <span class="pl-s1">othr</span><span class="pl-kos">:</span> <span class="pl-c1">&amp;</span><span class="pl-smi">f64</span><span class="pl-kos">)</span> -&gt; <span class="pl-smi">f64</span> <span class="pl-kos">{</span>
        othr + <span class="pl-c1">2.0</span>
    <span class="pl-kos">}</span>
<span class="pl-kos">}</span>

<span class="pl-k">fn</span> <span class="pl-en">main</span><span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-kos">{</span>
    <span class="pl-k">let</span> f = <span class="pl-v">Test</span><span class="pl-kos">;</span>
    <span class="pl-en">println</span><span class="pl-en">!</span><span class="pl-kos">(</span><span class="pl-s">"f + 3:   {}"</span>, f + <span class="pl-c1">3</span><span class="pl-kos">)</span><span class="pl-kos">;</span>
    <span class="pl-en">println</span><span class="pl-en">!</span><span class="pl-kos">(</span><span class="pl-s">"f + 3.0: {}"</span>, f + <span class="pl-c1">3.0f64</span><span class="pl-kos">)</span><span class="pl-kos">;</span>
<span class="pl-kos">}</span></pre></div>
<p dir="auto">compiles and runs as expected</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="[tyler@mac ~]$ ./test
f + 3:   4
f + 3.0: 5"><pre class="notranslate"><code class="notranslate">[tyler@mac ~]$ ./test
f + 3:   4
f + 3.0: 5
</code></pre></div>
<p dir="auto">Hello,</p>
<p dir="auto">The following <a href="http://is.gd/zPTDbV" rel="nofollow">code</a>:</p>
<div class="highlight highlight-source-rust notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="use std::default::Default;

type Foo = u16;

#[deriving(Default)]
struct Bar {
    pub foo: Foo,
}

fn main() {
    let baz = 0u;
    match baz {
        _ =&gt; assert!(0, 0),
    }
}"><pre class="notranslate"><span class="pl-k">use</span> std<span class="pl-kos">::</span>default<span class="pl-kos">::</span><span class="pl-v">Default</span><span class="pl-kos">;</span>

<span class="pl-k">type</span> <span class="pl-smi">Foo</span> = <span class="pl-smi">u16</span><span class="pl-kos">;</span>

<span class="pl-c1">#<span class="pl-kos">[</span>deriving<span class="pl-kos">(</span><span class="pl-v">Default</span><span class="pl-kos">)</span><span class="pl-kos">]</span></span>
<span class="pl-k">struct</span> <span class="pl-smi">Bar</span> <span class="pl-kos">{</span>
    <span class="pl-k">pub</span> <span class="pl-c1">foo</span><span class="pl-kos">:</span> <span class="pl-smi">Foo</span><span class="pl-kos">,</span>
<span class="pl-kos">}</span>

<span class="pl-k">fn</span> <span class="pl-en">main</span><span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-kos">{</span>
    <span class="pl-k">let</span> baz = <span class="pl-c1">0</span>u<span class="pl-kos">;</span>
    <span class="pl-k">match</span> baz <span class="pl-kos">{</span>
        _ =&gt; <span class="pl-en">assert</span><span class="pl-en">!</span><span class="pl-kos">(</span><span class="pl-c1">0</span>, <span class="pl-c1">0</span><span class="pl-kos">)</span><span class="pl-kos">,</span>
    <span class="pl-kos">}</span>
<span class="pl-kos">}</span></pre></div>
<p dir="auto">makes the compiler panic:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="&lt;std macros&gt;:8:12: 13:23 error: mismatched types: expected `bool`, found `_` (expected bool, found integral variable)
&lt;std macros&gt;:8         if !$cond {
&lt;std macros&gt;:9             panic!($($arg),+)
&lt;std macros&gt;:10         }
&lt;std macros&gt;:11     );
&lt;std macros&gt;:12 )
error: internal compiler error: unexpected panic
note: the compiler unexpectedly panicked. 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' panicked at 'index out of bounds: the len is 12 but the index is 12', /Users/rustbuild/src/rust-buildbot/slave/nightly-mac/build/src/libsyntax/lib.rs:1"><pre class="notranslate"><code class="notranslate">&lt;std macros&gt;:8:12: 13:23 error: mismatched types: expected `bool`, found `_` (expected bool, found integral variable)
&lt;std macros&gt;:8         if !$cond {
&lt;std macros&gt;:9             panic!($($arg),+)
&lt;std macros&gt;:10         }
&lt;std macros&gt;:11     );
&lt;std macros&gt;:12 )
error: internal compiler error: unexpected panic
note: the compiler unexpectedly panicked. 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' panicked at 'index out of bounds: the len is 12 but the index is 12', /Users/rustbuild/src/rust-buildbot/slave/nightly-mac/build/src/libsyntax/lib.rs:1
</code></pre></div>
<p dir="auto">The backtrace is as follows:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="   1:        0x105e915f2 - rt::backtrace::imp::write::he31e36fe59b39292ugt
   2:        0x105e946ad - failure::on_fail::h7c2689f722982652nCt
   3:        0x1060ff575 - unwind::begin_unwind_inner::h09866e00e97d31fbI2c
   4:        0x1060ff1bf - unwind::begin_unwind_fmt::h443e47d11b48984fTZc
   5:        0x1060fef62 - rust_begin_unwind
   6:        0x106149bfc - panicking::panic_fmt::hc979f6c0b0157f68RQl
   7:        0x106152341 - panicking::panic_bounds_check::hfad71607541b5567pPl
   8:        0x103e5a1e5 - codemap::FileMap::get_line::h40447e4b57225531m4E
   9:        0x103e888d3 - diagnostic::emit::hd3a2cf9de9dee335wvG
  10:        0x103e85168 - diagnostic::EmitterWriter.Emitter::emit::h8d15319a02e5e7a2lrG
  11:        0x103e83955 - diagnostic::Handler::emit::h444f90359ca9a887F8F
  12:        0x103e5637b - diagnostic::SpanHandler::span_err::he607876660b5f38fEWF
  13:        0x103208f8d - middle::typeck::infer::error_reporting::InferCtxt&lt;'a, 'tcx&gt;.ErrorReporting&lt;'tcx&gt;::report_type_error::h295fd9075d7add0fEMv
  14:        0x1030a12d4 - middle::typeck::check::demand::suptype::h60784e61bbbd5b6eyCd
  15:        0x1031b806d - middle::typeck::check::check_expr_has_type::closure.110801
  16:        0x1031b6216 - middle::typeck::check::check_expr_with_unifier::h8837607ae16c10b8Nzm
  17:        0x1031b0442 - middle::typeck::check::check_expr_with_unifier::h8837607ae16c10b8Nzm
  18:        0x1030a44c2 - middle::typeck::check::_match::check_match::h405380e6f6849c885P8
  19:        0x1031b06f3 - middle::typeck::check::check_expr_with_unifier::h8837607ae16c10b8Nzm
  20:        0x10316a4cf - middle::typeck::check::check_block_with_expected::he7085b8c57c115ecvzo
  21:        0x103143f70 - middle::typeck::check::check_fn::h604cf1058f7c9abce0i
  22:        0x103166b1e - middle::typeck::check::check_bare_fn::h42d50bc38b24ab59jPi
  23:        0x103162ad1 - middle::typeck::check::check_item::ha935ead12b2c5b2ft9i
  24:        0x103166840 - middle::typeck::check::check_item_types::h466c6c16edcec5c9tOi
  25:        0x1034ea896 - util::common::time::h12864813766357117792
  26:        0x1034e9d14 - middle::typeck::check_crate::h1acd5e14d073c903cwM
  27:        0x102ad79a3 - driver::driver::phase_3_run_analysis_passes::h098de55f4a14acee2eS
  28:        0x102acbecc - driver::driver::compile_input::h814765d870318dcf8VR
  29:        0x102b49e65 - driver::run_compiler::h54cbb685f3e65071gUT
  30:        0x102b4863e - driver::run::closure.59668
  31:        0x1029605ae - task::TaskBuilder::try_future::closure.38921
  32:        0x105e1f2e4 - task::TaskBuilder::spawn_internal::closure.24355
  33:        0x1060fcddd - task::Task::spawn::closure.5917
  34:        0x1061616ac - rust_try_inner
  35:        0x106161696 - rust_try
  36:        0x1060fceb7 - unwind::try::h207282f5be16daac3Qc
  37:        0x1060fcc8c - task::Task::run::h7eee475ba5444e2993b
  38:        0x1060fc98f - task::Task::spawn::closure.5893
  39:        0x1060fe627 - thread::thread_start::hc58864c152053492Wnc
  40:     0x7fff986072fc - _pthread_body
  41:     0x7fff98607279 - _pthread_body"><pre class="notranslate"><code class="notranslate">   1:        0x105e915f2 - rt::backtrace::imp::write::he31e36fe59b39292ugt
   2:        0x105e946ad - failure::on_fail::h7c2689f722982652nCt
   3:        0x1060ff575 - unwind::begin_unwind_inner::h09866e00e97d31fbI2c
   4:        0x1060ff1bf - unwind::begin_unwind_fmt::h443e47d11b48984fTZc
   5:        0x1060fef62 - rust_begin_unwind
   6:        0x106149bfc - panicking::panic_fmt::hc979f6c0b0157f68RQl
   7:        0x106152341 - panicking::panic_bounds_check::hfad71607541b5567pPl
   8:        0x103e5a1e5 - codemap::FileMap::get_line::h40447e4b57225531m4E
   9:        0x103e888d3 - diagnostic::emit::hd3a2cf9de9dee335wvG
  10:        0x103e85168 - diagnostic::EmitterWriter.Emitter::emit::h8d15319a02e5e7a2lrG
  11:        0x103e83955 - diagnostic::Handler::emit::h444f90359ca9a887F8F
  12:        0x103e5637b - diagnostic::SpanHandler::span_err::he607876660b5f38fEWF
  13:        0x103208f8d - middle::typeck::infer::error_reporting::InferCtxt&lt;'a, 'tcx&gt;.ErrorReporting&lt;'tcx&gt;::report_type_error::h295fd9075d7add0fEMv
  14:        0x1030a12d4 - middle::typeck::check::demand::suptype::h60784e61bbbd5b6eyCd
  15:        0x1031b806d - middle::typeck::check::check_expr_has_type::closure.110801
  16:        0x1031b6216 - middle::typeck::check::check_expr_with_unifier::h8837607ae16c10b8Nzm
  17:        0x1031b0442 - middle::typeck::check::check_expr_with_unifier::h8837607ae16c10b8Nzm
  18:        0x1030a44c2 - middle::typeck::check::_match::check_match::h405380e6f6849c885P8
  19:        0x1031b06f3 - middle::typeck::check::check_expr_with_unifier::h8837607ae16c10b8Nzm
  20:        0x10316a4cf - middle::typeck::check::check_block_with_expected::he7085b8c57c115ecvzo
  21:        0x103143f70 - middle::typeck::check::check_fn::h604cf1058f7c9abce0i
  22:        0x103166b1e - middle::typeck::check::check_bare_fn::h42d50bc38b24ab59jPi
  23:        0x103162ad1 - middle::typeck::check::check_item::ha935ead12b2c5b2ft9i
  24:        0x103166840 - middle::typeck::check::check_item_types::h466c6c16edcec5c9tOi
  25:        0x1034ea896 - util::common::time::h12864813766357117792
  26:        0x1034e9d14 - middle::typeck::check_crate::h1acd5e14d073c903cwM
  27:        0x102ad79a3 - driver::driver::phase_3_run_analysis_passes::h098de55f4a14acee2eS
  28:        0x102acbecc - driver::driver::compile_input::h814765d870318dcf8VR
  29:        0x102b49e65 - driver::run_compiler::h54cbb685f3e65071gUT
  30:        0x102b4863e - driver::run::closure.59668
  31:        0x1029605ae - task::TaskBuilder::try_future::closure.38921
  32:        0x105e1f2e4 - task::TaskBuilder::spawn_internal::closure.24355
  33:        0x1060fcddd - task::Task::spawn::closure.5917
  34:        0x1061616ac - rust_try_inner
  35:        0x106161696 - rust_try
  36:        0x1060fceb7 - unwind::try::h207282f5be16daac3Qc
  37:        0x1060fcc8c - task::Task::run::h7eee475ba5444e2993b
  38:        0x1060fc98f - task::Task::spawn::closure.5893
  39:        0x1060fe627 - thread::thread_start::hc58864c152053492Wnc
  40:     0x7fff986072fc - _pthread_body
  41:     0x7fff98607279 - _pthread_body
</code></pre></div>
<p dir="auto"><a href="https://github.com/rust-lang/rust/issues?q=is%3Aissue+is%3Aopen+index+out+of+bounds%3A+the+len+is+12+but+the+index+is+12">It seems</a> there are quite many bug reports with similar panic messages. I hope my snippet of code can shed some more light on the problem. Thank you.</p>
<p dir="auto">Regards,<br>
Ivan</p>