From 0c383a8505dbe24fa5e178a7818eb149ca3f13a8 Mon Sep 17 00:00:00 2001 From: Ryan VanderMeulen Date: Mon, 31 Aug 2026 12:47:49 +0000 Subject: [PATCH] Bug 2067405 - mark hal's sInitialized as maybe_unused. r=gsvelto Every read of sInitialized happens inside a MOZ_ASSERT, so opt builds only ever write to it. clang 23 flags that under -Wunused-but-set-global, which -Wall now enables transitively via -Wunused-but-set-variable, busting the plain clang-trunk build. Differential Revision: https://phabricator.services.mozilla.com/D322068 --- hal/Hal.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hal/Hal.cpp b/hal/Hal.cpp index db97faf0bf22..60abe9d5937b 100644 --- a/hal/Hal.cpp +++ b/hal/Hal.cpp @@ -48,7 +48,7 @@ using namespace mozilla::dom; namespace mozilla::hal { -static bool sInitialized = false; +[[maybe_unused]] static bool sInitialized = false; mozilla::LogModule* GetHalLog() { static mozilla::LazyLogModule sHalLog("hal");