Repository: rust
Issue: Compilation issue [resolved with cargo clean]
Labels: I-ICE,T-compiler,A-incr-comp,C-bug,S-needs-repro

<!--
Thank you for finding an Internal Compiler Error! 🧊  If possible, try to provide
a minimal verifiable example. You can read "Rust Bug Minimization Patterns" for
how to create smaller examples.
http://blog.pnkfx.org/blog/2019/11/18/rust-bug-minimization-patterns/
-->

### Code

```Rust
pub fn easy_vec_ui(
    mut easy_vec_ui_resource: ResMut<EasyVecUi>,
    connected_players: Res<ConnectedPlayers>,
    run_trigger: Res<RunTrigger>,
) {

    let right_data_vec = vec![
            String::from(format!("( Shift + E ) <--- Client Run Trigger Index [{}] ---> ( Shift + D )", run_trigger.get_trigger_idx())),
            String::from(format!("( Shift + F ) All Clients Run Trigger: [{}]", run_trigger.get_triggers_ref()[run_trigger.get_trigger_idx()])),
        ];
    easy_vec_ui_resource.inject_vec_right(right_data_vec);

    let mut left_data_vec: Vec<String> = Vec::new();
    let players_guard = connected_players.players.lock().unwrap(); // Lock the connected players to read player data
    for (uuid, player_status) in players_guard.iter() { // Iterate over each player and create a row for each one
        left_data_vec.push(String::from(format!("Player ID: [{}] Last heartbeat: [{:?}]", uuid, player_status.last_heartbeat)));
    }
    left_data_vec.push(String::from("_____________________________________________"));
    left_data_vec.push(String::from("Heart Beat Interface: Connected Players Above"));
    easy_vec_ui_resource.inject_vec_left(left_data_vec);
}
```


### Meta
<!--
If you're using the stable version of the compiler, you should also check if the
bug also exists in the beta or nightly versions.
-->

`rustc --version --verbose`:
```
<version>
```

### Error output

```
   Compiling minigolf_backend_server v0.1.0 (D:\bevy\donut\minigolf_backend_server)
thread 'rustc' panicked at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\compiler\rustc_middle\src\middle\exported_symbols.rs:41:58:
invalid enum variant tag while decoding `ExportedSymbol`, expected 0..6, actual 197
stack backtrace:
   0:     0x7ffd9e0e0f51 - std::backtrace_rs::backtrace::dbghelp64::trace
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\..\..\backtrace\src\backtrace\dbghelp64.rs:91 
   1:     0x7ffd9e0e0f51 - std::backtrace_rs::backtrace::trace_unsynchronized
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\..\..\backtrace\src\backtrace\mod.rs:66       
   2:     0x7ffd9e0e0f51 - std::sys::backtrace::_print_fmt
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\sys\backtrace.rs:66
   3:     0x7ffd9e0e0f51 - std::sys::backtrace::impl$0::print::impl$0::fmt
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\sys\backtrace.rs:39
   4:     0x7ffd9e112629 - core::fmt::rt::Argument::fmt
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/core\src\fmt\rt.rs:177
   5:     0x7ffd9e112629 - core::fmt::write
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/core\src\fmt\mod.rs:1178
   6:     0x7ffd9e0d7117 - std::io::Write::write_fmt<std::sys::pal::windows::stdio::Stderr>
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\io\mod.rs:1823
   7:     0x7ffd9e0e4069 - std::panicking::default_hook::closure$1      
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\panicking.rs:266
   8:     0x7ffd9e0e3bec - std::panicking::default_hook
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\panicking.rs:293
   9:     0x7ffd9f635e40 - memchr
  10:     0x7ffd9e0e4a7b - alloc::boxed::impl$50::call
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/alloc\src\boxed.rs:2245
  11:     0x7ffd9e0e4a7b - std::panicking::rust_panic_with_hook
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\panicking.rs:805
  12:     0x7ffd9e0e4886 - std::panicking::begin_panic_handler::closure$0
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\panicking.rs:671
  13:     0x7ffd9e0e1a0f - std::sys::backtrace::__rust_end_short_backtrace<std::panicking::begin_panic_handler::closure_env$0,never$>
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\sys\backtrace.rs:170
  14:     0x7ffd9e0e4496 - std::panicking::begin_panic_handler
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\panicking.rs:662
  15:     0x7ffda0ea47d4 - core::panicking::panic_fmt
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/core\src\panicking.rs:74
  16:     0x7ffd9f1b228f - <rustc_metadata[6691fbe6571c11b4]::creader::alloc_error_handler_spans::Finder as rustc_ast[fb8a06d0c4c179b8]::visit::Visitor>::visit_item
  17:     0x7ffd9dccef4e - rustc_ty_utils[67287b256ac86568]::ty::adt_sized_constraint
  18:     0x7ffd9dcade4d - rustc_ty_utils[67287b256ac86568]::ty::adt_sized_constraint
  19:     0x7ffd9dc7ffb2 - rustc_ty_utils[67287b256ac86568]::ty::adt_sized_constraint
  20:     0x7ffd9dcf95a0 - rustc_query_impl[1cbfc9fc16052fcf]::query_system
  21:     0x7ffd9f0b8f45 - rustc_codegen_ssa[64d598cc62316a48]::back::symbol_export::upstream_monomorphizations_provider
  22:     0x7ffd9dcd0e93 - rustc_ty_utils[67287b256ac86568]::ty::adt_sized_constraint
  23:     0x7ffd9dc4560a - rustc_ty_utils[67287b256ac86568]::ty::adt_sized_constraint
  24:     0x7ffda0341cc6 - <rustc_span[8754bfbf43f7048e]::def_id::DefIndex as rustc_query_impl[1cbfc9fc16052fcf]::profiling_support::SpecIntoSelfProfilingString>::spec_to_self_profile_string
  25:     0x7ffd9de4a7a3 - rustc_codegen_ssa[64d598cc62316a48]::back::symbol_export::upstream_monomorphizations_for_provider
  26:     0x7ffd9dcd11a0 - rustc_ty_utils[67287b256ac86568]::ty::adt_sized_constraint
  27:     0x7ffd9eb777ed - rustc_ty_utils[67287b256ac86568]::ty::self_ty_of_trait_impl_enabling_order_dep_trait_object_hack
  28:     0x7ffd9dcf1925 - rustc_query_impl[1cbfc9fc16052fcf]::query_system
  29:     0x7ffd9f4b2b55 - <rustc_middle[c5ee28e0fcbaddd6]::ty::instance::Instance>::upstream_monomorphization
  30:     0x7ffd9e4af583 - rustc_monomorphize[6d2945be1fb3e4b3]::polymorphize::unused_generic_params
  31:     0x7ffd9e4ac0eb - rustc_monomorphize[6d2945be1fb3e4b3]::polymorphize::unused_generic_params
  32:     0x7ffd9e4a1ad1 - rustc_monomorphize[6d2945be1fb3e4b3]::partitioning::collect_and_partition_mono_items
  33:     0x7ffd9dcd1267 - rustc_ty_utils[67287b256ac86568]::ty::adt_sized_constraint
  34:     0x7ffd9dcb88ed - rustc_ty_utils[67287b256ac86568]::ty::adt_sized_constraint
  35:     0x7ffd9dc4024a - rustc_ty_utils[67287b256ac86568]::ty::adt_sized_constraint
  36:     0x7ffda0314058 - <rustc_query_impl[1cbfc9fc16052fcf]::plumbing::QueryCtxt as rustc_query_system[9660e097ca113b0a]::query::QueryContext>::depth_limit_error
  37:     0x7ffda02db45f - <rustc_ty_utils[67287b256ac86568]::opaque_types::OpaqueTypeCollector as rustc_type_ir[20c798ba42da02c9]::visit::TypeVisitor<rustc_middle[c5ee28e0fcbaddd6]::ty::context::TyCtxt>>::visit_ty  
  38:     0x7ffd9eb51d66 - rustc_ty_utils[67287b256ac86568]::ty::self_ty_of_trait_impl_enabling_order_dep_trait_object_hack
  39:     0x7ffd9eb51a1e - rustc_ty_utils[67287b256ac86568]::ty::self_ty_of_trait_impl_enabling_order_dep_trait_object_hack
  40:     0x7ffd9dc7ff22 - rustc_ty_utils[67287b256ac86568]::ty::adt_sized_constraint
  41:     0x7ffd9dcf95a0 - rustc_query_impl[1cbfc9fc16052fcf]::query_system
  42:     0x7ffd9f160fd3 - <rustc_metadata[6691fbe6571c11b4]::rmeta::encoder::EncodeContext as rustc_span[8754bfbf43f7048e]::SpanEncoder>::encode_symbol
  43:     0x7ffd9de8c5de - rustc_metadata[6691fbe6571c11b4]::rmeta::encoder::encode_metadata
  44:     0x7ffd9de94801 - rustc_metadata[6691fbe6571c11b4]::fs::encode_and_write_metadata
  45:     0x7ffd9b1f2793 - <rustc_interface[ab63cb8dd572d7f1]::queries::Linker>::codegen_and_build_linker
  46:     0x7ffd9b1a6f70 - _rust_alloc_error_handler
  47:     0x7ffd9b1a2a16 - _rust_alloc_error_handler
  48:     0x7ffd9b1ac5db - _rust_alloc_error_handler
  49:     0x7ffd9e0f640d - alloc::boxed::impl$48::call_once
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/alloc\src\boxed.rs:2231
  50:     0x7ffd9e0f640d - alloc::boxed::impl$48::call_once
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/alloc\src\boxed.rs:2231
  51:     0x7ffd9e0f640d - std::sys::pal::windows::thread::impl$0::new::thread_start
                               at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\sys\pal\windows\thread.rs:55
  53:     0x7ffe5545cc91 - RtlUserThreadStart
error: the compiler unexpectedly panicked. this is a bug.

note: we would appreciate a bug report: https://github.com/rust-lang/rust/issues/new?labels=C-bug%2C+I-ICE%2C+T-compiler&template=ice.md        

note: rustc 1.82.0 (f6e511eec 2024-10-15) running on x86_64-pc-windows-msvc

note: compiler flags: --crate-type lib -C embed-bitcode=no -C debuginfo=2 -C incremental=[REDACTED]

note: some of the compiler flags provided by cargo are hidden

query stack during panic:
#0 [exported_symbols] collecting exported symbols for crate `443`       
#1 [upstream_monomorphizations] collecting available upstream monomorphizations
end of query stack
there was a panic while trying to force a dep node
try_mark_green dep node stack:
#0 exported_symbols(minigolf_backend_server[1ad1])
end of try_mark_green dep node stack
```

<!--
Include a backtrace in the code block by setting `RUST_BACKTRACE=1` in your
environment. E.g. `RUST_BACKTRACE=1 cargo build`.
-->
<details><summary><strong>Backtrace</strong></summary>
<p>

```
I don't know enough to understand what backtrace was looking for but I was able to resolve the issue with a cargo clean and cargo run.
```

</p>
</details>