summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLioncash <mathew1800@gmail.com>2018-11-21 18:30:58 -0500
committerLioncash <mathew1800@gmail.com>2018-11-21 18:31:01 -0500
commit0e35f1bb18b71fcb936b3a00e6bda0fa82a0b59c (patch)
tree53941cfab7535f6fa7df24ee777d086ce4f495ec /src
parent568bcbc29d099f030f7022838cd788dfe2feba45 (diff)
kernel/handle_table: Move private static functions into the cpp file
These don't depend on class state, and are effectively implementation details, so they can go into the cpp file .
Diffstat (limited to 'src')
-rw-r--r--src/core/hle/kernel/handle_table.cpp9
-rw-r--r--src/core/hle/kernel/handle_table.h7
2 files changed, 9 insertions, 7 deletions
diff --git a/src/core/hle/kernel/handle_table.cpp b/src/core/hle/kernel/handle_table.cpp
index 9f2b996c4..1bf79b692 100644
--- a/src/core/hle/kernel/handle_table.cpp
+++ b/src/core/hle/kernel/handle_table.cpp
@@ -12,6 +12,15 @@
#include "core/hle/kernel/thread.h"
namespace Kernel {
+namespace {
+constexpr u16 GetSlot(Handle handle) {
+ return handle >> 15;
+}
+
+constexpr u16 GetGeneration(Handle handle) {
+ return handle & 0x7FFF;
+}
+} // Anonymous namespace
HandleTable::HandleTable() {
next_generation = 1;
diff --git a/src/core/hle/kernel/handle_table.h b/src/core/hle/kernel/handle_table.h
index ae3116afc..e3f3e3fb8 100644
--- a/src/core/hle/kernel/handle_table.h
+++ b/src/core/hle/kernel/handle_table.h
@@ -93,13 +93,6 @@ private:
/// This is the maximum limit of handles allowed per process in Horizon
static constexpr std::size_t MAX_COUNT = 1024;
- static u16 GetSlot(Handle handle) {
- return handle >> 15;
- }
- static u16 GetGeneration(Handle handle) {
- return handle & 0x7FFF;
- }
-
/// Stores the Object referenced by the handle or null if the slot is empty.
std::array<SharedPtr<Object>, MAX_COUNT> objects;