diff options
| author | bors <bors@rust-lang.org> | 2024-04-15 14:36:12 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2024-04-15 14:36:12 +0000 |
| commit | 023084804e5e8ea42877451c2b3030e7050281cc (patch) | |
| tree | ff7e564f1dc1f6a79b2ef0c4cfd6ccf39805e342 /library/std/src | |
| parent | 84e729a59f216cc64755788a470f165429a731f4 (diff) | |
| parent | 5934aaaa973349c0ff6050e88d6a66a0fe196dda (diff) | |
Auto merge of #123937 - RalfJung:miri-link-section, r=oli-obk
Miri on Windows: run .CRT$XLB linker section on thread-end Hopefully fixes https://github.com/rust-lang/rust/issues/123583 First commit is originally by `@bjorn3` r? `@oli-obk` Cc `@ChrisDenton`
Diffstat (limited to 'library/std/src')
| -rw-r--r-- | library/std/src/sys/pal/windows/thread_local_key.rs | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/library/std/src/sys/pal/windows/thread_local_key.rs b/library/std/src/sys/pal/windows/thread_local_key.rs index 1d9cb316a45..4c00860dae3 100644 --- a/library/std/src/sys/pal/windows/thread_local_key.rs +++ b/library/std/src/sys/pal/windows/thread_local_key.rs @@ -276,6 +276,7 @@ unsafe fn register_dtor(key: &'static StaticKey) { // the address of the symbol to ensure it sticks around. #[link_section = ".CRT$XLB"] +#[cfg_attr(miri, used)] // Miri only considers explicitly `#[used]` statics for `lookup_link_section` pub static p_thread_callback: unsafe extern "system" fn(c::LPVOID, c::DWORD, c::LPVOID) = on_tls_callback; |
