title: RuntimeError: unreachable in rustwasm
body: <p>I am getting the error &quot;RuntimeError: unreachable in rustwasm&quot; for the code</p>
  <p>error message:</p>
  <pre><code>Uncaught (in promise) RuntimeError: unreachable
      at __rust_start_panic (http://127.0.0.1:8080/wasm_bg.wasm:wasm-function[346]:0x274ec)
      at rust_panic (http://127.0.0.1:8080/wasm_bg.wasm:wasm-function[254]:0x26d0b)
      at std::panicking::rust_panic_with_hook::hb07b303a83b6d242 (http://127.0.0.1:8080/wasm_bg.wasm:wasm-function[168]:0x24a47)
      at rust_begin_unwind (http://127.0.0.1:8080/wasm_bg.wasm:wasm-function[228]:0x267ed)
      at core::panicking::panic_fmt::h62f7e605cdf65d83 
      at core::panicking::panic_bounds_check::ha440f41d0e4eca5f 
      at virtualdom::parseNode::h9ba47b7b20126d66 
      at run ()
      at init ()
  </code></pre>
  <p><a href="https://play.rust-lang.org/?version=stable&amp;mode=debug&amp;edition=2018&amp;gist=ac403a9043e49b7a2fc3814a692b8d49" rel="nofollow noreferrer">https://play.rust-lang.org/?version=stable&amp;mode=debug&amp;edition=2018&amp;gist=ac403a9043e49b7a2fc3814a692b8d49</a></p>
  <p>I have following questions ?</p>
  <ol>
  <li>is it coming from <code>parseNode</code> function?</li>
  <li>is it because of <code>dm.children[i]</code> overflowed? or some functions removed at runtime in the background in wasm?</li>
  <li>I tried to hook <code>panic::set_hook(Box::new(console_error_panic_hook::hook));</code> but did not help much! How should I debug these kind of errors?</li>
  </ol>