From 4a21e37fa12c979172d7747754af74487538cd28 Mon Sep 17 00:00:00 2001 From: Richard Barnes Date: Mon, 26 Oct 2026 15:32:40 -0700 Subject: [PATCH] Remove unreachable break after LOG(FATAL) in LogOnce.cpp (#59520) Summary: Pull Request resolved: https://github.com/react/react-native/pull/59520 Clang reports `-Wunreachable-code-break` here: the `break` follows `LOG(FATAL)`, which never returns, so control can never reach the `break`. Removing it silences the warning and does not change behavior. It ends the last label of the switch, so it is redundant anyway. Changelog: [Internal] Reviewed By: dtolnay Differential Revision: D126709681 --- packages/react-native/ReactCxxPlatform/react/logging/LogOnce.cpp | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/react-native/ReactCxxPlatform/react/logging/LogOnce.cpp b/packages/react-native/ReactCxxPlatform/react/logging/LogOnce.cpp index c35fa9b34230..c4df4a8b3b65 100644 --- a/packages/react-native/ReactCxxPlatform/react/logging/LogOnce.cpp +++ b/packages/react-native/ReactCxxPlatform/react/logging/LogOnce.cpp @@ -34,7 +34,6 @@ LogOnceWrapper::~LogOnceWrapper() { case Severity::Fatal: default: LOG(FATAL) << message; - break; } loggedMessages.insert(message);