diff options
author | fearlessTobi <thm.frey@gmail.com> | 2018-09-15 15:21:06 +0200 |
---|---|---|
committer | fearlessTobi <thm.frey@gmail.com> | 2018-09-15 15:21:06 +0200 |
commit | 63c2e32e207d31ecadd9022e1d7cd705c9febac8 (patch) | |
tree | 8a90e8ef2804f147dff7225a543a8740ecf7160c /src/common/alignment.h | |
parent | Merge pull request #1310 from lioncash/kernel-ns (diff) | |
download | yuzu-63c2e32e207d31ecadd9022e1d7cd705c9febac8.tar yuzu-63c2e32e207d31ecadd9022e1d7cd705c9febac8.tar.gz yuzu-63c2e32e207d31ecadd9022e1d7cd705c9febac8.tar.bz2 yuzu-63c2e32e207d31ecadd9022e1d7cd705c9febac8.tar.lz yuzu-63c2e32e207d31ecadd9022e1d7cd705c9febac8.tar.xz yuzu-63c2e32e207d31ecadd9022e1d7cd705c9febac8.tar.zst yuzu-63c2e32e207d31ecadd9022e1d7cd705c9febac8.zip |
Diffstat (limited to 'src/common/alignment.h')
-rw-r--r-- | src/common/alignment.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/common/alignment.h b/src/common/alignment.h index b9dd38746..225770fab 100644 --- a/src/common/alignment.h +++ b/src/common/alignment.h @@ -8,13 +8,13 @@ namespace Common { template <typename T> -constexpr T AlignUp(T value, size_t size) { +constexpr T AlignUp(T value, std::size_t size) { static_assert(std::is_unsigned_v<T>, "T must be an unsigned value."); return static_cast<T>(value + (size - value % size) % size); } template <typename T> -constexpr T AlignDown(T value, size_t size) { +constexpr T AlignDown(T value, std::size_t size) { static_assert(std::is_unsigned_v<T>, "T must be an unsigned value."); return static_cast<T>(value - value % size); } |