From 5db165504ada6fde86f93d275a0d6380263ee381 Mon Sep 17 00:00:00 2001 From: Zachary S Date: Fri, 5 Jul 2024 17:59:46 -0500 Subject: [PATCH] Attempt to fix CI --- library/std/src/sys/exit_guard.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/library/std/src/sys/exit_guard.rs b/library/std/src/sys/exit_guard.rs index a1b0309b003ea..ad6246cc83180 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. }