summaryrefslogtreecommitdiff
path: root/Kernel/KResult.h
diff options
context:
space:
mode:
Diffstat (limited to 'Kernel/KResult.h')
-rw-r--r--Kernel/KResult.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/Kernel/KResult.h b/Kernel/KResult.h
index 5039af8b3d..341df32baa 100644
--- a/Kernel/KResult.h
+++ b/Kernel/KResult.h
@@ -143,7 +143,7 @@ public:
[[nodiscard]] ALWAYS_INLINE KResult error() const
{
- ASSERT(m_is_error);
+ VERIFY(m_is_error);
return m_error;
}
@@ -151,20 +151,20 @@ public:
[[nodiscard]] ALWAYS_INLINE T& value()
{
- ASSERT(!m_is_error);
+ VERIFY(!m_is_error);
return *reinterpret_cast<T*>(&m_storage);
}
[[nodiscard]] ALWAYS_INLINE const T& value() const
{
- ASSERT(!m_is_error);
+ VERIFY(!m_is_error);
return *reinterpret_cast<T*>(&m_storage);
}
[[nodiscard]] ALWAYS_INLINE T release_value()
{
- ASSERT(!m_is_error);
- ASSERT(m_have_storage);
+ VERIFY(!m_is_error);
+ VERIFY(m_have_storage);
T released_value(move(*reinterpret_cast<T*>(&m_storage)));
value().~T();
m_have_storage = false;