diff options
author | bunnei <bunneidev@gmail.com> | 2021-03-24 02:42:04 +0100 |
---|---|---|
committer | bunnei <bunneidev@gmail.com> | 2021-03-24 02:42:04 +0100 |
commit | fb91647bcad788898d90c2eb95a3e1af4304d6d9 (patch) | |
tree | 751620af9b0634cbb8a7cf9400e0af55a2abfb93 /src/core/hle/kernel/k_memory_region_type.h | |
parent | hle: kernel: k_memory_region: Minor code cleanup. (diff) | |
download | yuzu-fb91647bcad788898d90c2eb95a3e1af4304d6d9.tar yuzu-fb91647bcad788898d90c2eb95a3e1af4304d6d9.tar.gz yuzu-fb91647bcad788898d90c2eb95a3e1af4304d6d9.tar.bz2 yuzu-fb91647bcad788898d90c2eb95a3e1af4304d6d9.tar.lz yuzu-fb91647bcad788898d90c2eb95a3e1af4304d6d9.tar.xz yuzu-fb91647bcad788898d90c2eb95a3e1af4304d6d9.tar.zst yuzu-fb91647bcad788898d90c2eb95a3e1af4304d6d9.zip |
Diffstat (limited to 'src/core/hle/kernel/k_memory_region_type.h')
-rw-r--r-- | src/core/hle/kernel/k_memory_region_type.h | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/src/core/hle/kernel/k_memory_region_type.h b/src/core/hle/kernel/k_memory_region_type.h index 5ea5d2ceb..a05e66677 100644 --- a/src/core/hle/kernel/k_memory_region_type.h +++ b/src/core/hle/kernel/k_memory_region_type.h @@ -41,20 +41,9 @@ constexpr size_t BitsForDeriveDense(size_t n) { } class KMemoryRegionTypeValue { -private: - using ValueType = typename std::underlying_type<KMemoryRegionType>::type; - -private: - ValueType m_value{}; - size_t m_next_bit{}; - bool m_finalized{}; - bool m_sparse_only{}; - bool m_dense_only{}; - -private: - constexpr KMemoryRegionTypeValue(ValueType v) : m_value(v) {} - public: + using ValueType = std::underlying_type_t<KMemoryRegionType>; + constexpr KMemoryRegionTypeValue() = default; constexpr operator KMemoryRegionType() const { @@ -139,6 +128,16 @@ public: constexpr bool IsAncestorOf(ValueType v) const { return (m_value | v) == v; } + +private: + constexpr KMemoryRegionTypeValue(ValueType v) : m_value(v) {} + +private: + ValueType m_value{}; + size_t m_next_bit{}; + bool m_finalized{}; + bool m_sparse_only{}; + bool m_dense_only{}; }; } // namespace impl |