about summary refs log tree commit diff
path: root/library/std/src
diff options
context:
space:
mode:
authorZachary S <zasample18+github@gmail.com>2024-07-05 17:59:46 -0500
committerZachary S <zasample18+github@gmail.com>2024-07-05 17:59:46 -0500
commit5db165504ada6fde86f93d275a0d6380263ee381 (patch)
treeaf8d015f762cddf307e7364645edd720d025ac20 /library/std/src
parenta6093701437be909614bc49d63406dfaa63d3b13 (diff)
downloadrust-5db165504ada6fde86f93d275a0d6380263ee381.tar.gz
rust-5db165504ada6fde86f93d275a0d6380263ee381.zip
Attempt to fix CI
Diffstat (limited to 'library/std/src')
-rw-r--r--library/std/src/sys/exit_guard.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/library/std/src/sys/exit_guard.rs b/library/std/src/sys/exit_guard.rs
index a1b0309b003..ad6246cc831 100644
--- a/library/std/src/sys/exit_guard.rs
+++ b/library/std/src/sys/exit_guard.rs
@@ -19,6 +19,7 @@ cfg_if::cfg_if! {
         /// * If it is called again on the same thread as the first call, it will abort.
         /// * If it is called again on a different thread, it will wait in a loop
         ///   (waiting for the process to exit).
+        #[cfg_attr(any(test, doctest), allow(dead_code))]
         pub(crate) fn unique_thread_exit() {
             let this_thread_id = unsafe { libc::pthread_self() };
             use crate::sync::{Mutex, PoisonError};
@@ -54,6 +55,7 @@ cfg_if::cfg_if! {
         ///
         /// Mitigation is ***NOT*** implemented on this platform, either because this platform
         /// is not affected, or because mitigation is not yet implemented for this platform.
+        #[cfg_attr(any(test, doctest), allow(dead_code))]
         pub(crate) fn unique_thread_exit() {
             // Mitigation not required on platforms where `exit` is thread-safe.
         }