summaryrefslogtreecommitdiff
path: root/Kernel/Arch/x86/RegisterState.h
diff options
context:
space:
mode:
authorBrian Gianforcaro <bgianf@serenityos.org>2021-09-05 00:57:53 -0700
committerAndreas Kling <kling@serenityos.org>2021-09-05 20:08:57 +0200
commit472454cdeda1ab87e879670f44993960013973ff (patch)
treead8c5c51d9ce3fcab18579f573aa35dd8c2a22a2 /Kernel/Arch/x86/RegisterState.h
parent112de58fe0601ef95544ab474f35ade14f947391 (diff)
downloadserenity-472454cdeda1ab87e879670f44993960013973ff.zip
Kernel: Switch static_asserts of a type size to AK::AssertSize
This will provide better debug ability when the size comparison fails.
Diffstat (limited to 'Kernel/Arch/x86/RegisterState.h')
-rw-r--r--Kernel/Arch/x86/RegisterState.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/Kernel/Arch/x86/RegisterState.h b/Kernel/Arch/x86/RegisterState.h
index cefd54209b..ceb7f3ec73 100644
--- a/Kernel/Arch/x86/RegisterState.h
+++ b/Kernel/Arch/x86/RegisterState.h
@@ -121,7 +121,7 @@ struct [[gnu::packed]] RegisterState {
#else
# define REGISTER_STATE_SIZE (22 * 8)
#endif
-static_assert(REGISTER_STATE_SIZE == sizeof(RegisterState));
+static_assert(AssertSize<RegisterState, REGISTER_STATE_SIZE>());
inline void copy_kernel_registers_into_ptrace_registers(PtraceRegisters& ptrace_regs, const RegisterState& kernel_regs)
{