summaryrefslogtreecommitdiffhomepage
path: root/dev/kernel/NeKit
diff options
context:
space:
mode:
authorAmlal El Mahrouss <amlal@nekernel.org>2025-09-28 14:18:55 +0200
committerGitHub <noreply@github.com>2025-09-28 14:18:55 +0200
commit643fd1890646442e97f61c323bb1342ccae8c46b (patch)
tree1dccc97ea6d52012d682f664995959fe7db9ddd1 /dev/kernel/NeKit
parentdfad97487744840f26ea8046d1a011688bd9edd0 (diff)
parent2d673e164b98db5eb08d4c41c6225fbe73ee82d7 (diff)
Merge pull request #66 from 0xf00sec/patch-2
feat: `T.Value` (ErrorOr.h)
Diffstat (limited to 'dev/kernel/NeKit')
-rw-r--r--dev/kernel/NeKit/CxxAbi.h8
-rw-r--r--dev/kernel/NeKit/ErrorOr.h2
2 files changed, 6 insertions, 4 deletions
diff --git a/dev/kernel/NeKit/CxxAbi.h b/dev/kernel/NeKit/CxxAbi.h
index 164a257d..4b7bf002 100644
--- a/dev/kernel/NeKit/CxxAbi.h
+++ b/dev/kernel/NeKit/CxxAbi.h
@@ -7,7 +7,7 @@
#include <NeKit/Defines.h>
-#ifndef __TOOLCHAINKIT__
+#ifndef __NECTI__
#define kAtExitMacDestructors (128)
@@ -17,10 +17,10 @@ struct atexit_func_entry_t {
void* dso_handle;
};
-typedef unsigned uarch_t;
+typedef Kernel::UInt32 uarch_t;
namespace cxxabiv1 {
-typedef void* __guard;
+typedef Kernel::SizeT* __guard;
}
-#endif // __GNUC__
+#endif // !__NECTI__
diff --git a/dev/kernel/NeKit/ErrorOr.h b/dev/kernel/NeKit/ErrorOr.h
index b653e0ee..52f0d6a9 100644
--- a/dev/kernel/NeKit/ErrorOr.h
+++ b/dev/kernel/NeKit/ErrorOr.h
@@ -38,6 +38,8 @@ class ErrorOr final {
return *this;
}
+ T Value() const { return *mRef; }
+
Ref<T>& Leak() { return mRef; }
Int32 Error() { return mId; }