fix: avoid NoDestructor on trivially destructible QueueState in release builds (#54554)

With DCHECKs off, SEQUENCE_CHECKER expands to nothing, leaving QueueState
trivially destructible and tripping base::NoDestructor's static_assert.
Give it a user-provided destructor so it is non-trivial in every config.


Claude-Session: https://claude.ai/code/session_01FsSQW86CrHuBNQNRMyPCex

Co-authored-by: Claude <noreply@anthropic.com>
This commit is contained in:
claude[bot]andClaude authored and GitHub committed 2026-09-29 11:02:05 -07:00
1 parent 2454be571a
commit e128184820
1 file changed
+3
+3
View File
@@ -22,6 +22,9 @@ namespace electron {
namespace {
struct QueueState {
// Non-trivial so NoDestructor accepts it when DCHECKs are off.
~QueueState() {} // NOLINT(modernize-use-equals-default)
SEQUENCE_CHECKER(sequence_checker);
bool release_scheduled = false;
bool shutdown_started = false;