From 679cc154e610a706e7357236928e0c8e2f28c686 Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Tue, 23 Feb 2021 21:11:53 +0100 Subject: [PATCH] Everywhere: Remove unused RELEASE_ASSERT macro --- AK/Assertions.h | 1 - AK/TestSuite.h | 7 ------- Kernel/Assertions.h | 5 ----- Userland/Libraries/LibC/assert.h | 1 - 4 files changed, 14 deletions(-) diff --git a/AK/Assertions.h b/AK/Assertions.h index bd50e66efef..95d8c53d8dd 100644 --- a/AK/Assertions.h +++ b/AK/Assertions.h @@ -33,7 +33,6 @@ # ifndef __serenity__ # define VERIFY assert # define VERIFY_NOT_REACHED() assert(false) -# define RELEASE_ASSERT assert # define TODO VERIFY_NOT_REACHED # endif #endif diff --git a/AK/TestSuite.h b/AK/TestSuite.h index 810b7e57678..9b7948f8b01 100644 --- a/AK/TestSuite.h +++ b/AK/TestSuite.h @@ -45,13 +45,6 @@ using AK::warnln; ::AK::warnln("\033[31;1mFAIL\033[0m: {}:{}: VERIFY({}) failed", __FILE__, __LINE__, #x); \ } while (false) -#undef RELEASE_ASSERT -#define RELEASE_ASSERT(x) \ - do { \ - if (!(x)) \ - ::AK::warnln("\033[31;1mFAIL\033[0m: {}:{}: RELEASE_ASSERT({}) failed", __FILE__, __LINE__, #x); \ - } while (false) - #undef VERIFY_NOT_REACHED #define VERIFY_NOT_REACHED() \ do { \ diff --git a/Kernel/Assertions.h b/Kernel/Assertions.h index 350e3caf831..f75860aadbb 100644 --- a/Kernel/Assertions.h +++ b/Kernel/Assertions.h @@ -41,11 +41,6 @@ do { \ asm volatile("ud2"); \ } while (0) -#define RELEASE_ASSERT(x) \ - do { \ - if (!(x)) \ - CRASH(); \ - } while (0) #define VERIFY_INTERRUPTS_DISABLED() VERIFY(!(cpu_flags() & 0x200)) #define VERIFY_INTERRUPTS_ENABLED() VERIFY(cpu_flags() & 0x200) diff --git a/Userland/Libraries/LibC/assert.h b/Userland/Libraries/LibC/assert.h index 7b8d26de9da..95152103090 100644 --- a/Userland/Libraries/LibC/assert.h +++ b/Userland/Libraries/LibC/assert.h @@ -50,7 +50,6 @@ __attribute__((noreturn)) void __assertion_failed(const char* msg); asm volatile("ud2"); \ } while (0) #define VERIFY assert -#define RELEASE_ASSERT assert #define TODO VERIFY_NOT_REACHED __END_DECLS