diff options
| author | 2019-07-19 21:49:54 -0400 | |
|---|---|---|
| committer | 2019-07-19 21:49:54 -0400 | |
| commit | febb88efc43ae171cc2880651b0665614c586504 (patch) | |
| tree | f0e2dac73ab3c10bb8354ccc793c655265715f75 /src | |
| parent | Kernel: Address Feedback (diff) | |
| download | yuzu-febb88efc43ae171cc2880651b0665614c586504.tar.gz yuzu-febb88efc43ae171cc2880651b0665614c586504.tar.xz yuzu-febb88efc43ae171cc2880651b0665614c586504.zip | |
Common/Alignment: Add noexcept where required.
Diffstat (limited to 'src')
| -rw-r--r-- | src/common/alignment.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/common/alignment.h b/src/common/alignment.h index 0ce218c60..88d5d3a65 100644 --- a/src/common/alignment.h +++ b/src/common/alignment.h | |||
| @@ -52,11 +52,11 @@ public: | |||
| 52 | using const_reference = const T&; | 52 | using const_reference = const T&; |
| 53 | 53 | ||
| 54 | public: | 54 | public: |
| 55 | pointer address(reference r) { | 55 | pointer address(reference r) noexcept { |
| 56 | return std::addressof(r); | 56 | return std::addressof(r); |
| 57 | } | 57 | } |
| 58 | 58 | ||
| 59 | const_pointer address(const_reference r) const { | 59 | const_pointer address(const_reference r) const noexcept { |
| 60 | return std::addressof(r); | 60 | return std::addressof(r); |
| 61 | } | 61 | } |
| 62 | 62 | ||
| @@ -82,17 +82,17 @@ public: | |||
| 82 | 82 | ||
| 83 | template <typename T2> | 83 | template <typename T2> |
| 84 | struct rebind { | 84 | struct rebind { |
| 85 | typedef AlignmentAllocator<T2, Align> other; | 85 | using other = AlignmentAllocator<T2, Align>; |
| 86 | }; | 86 | }; |
| 87 | 87 | ||
| 88 | bool operator!=(const AlignmentAllocator<T, Align>& other) const { | 88 | bool operator!=(const AlignmentAllocator<T, Align>& other) const noexcept { |
| 89 | return !(*this == other); | 89 | return !(*this == other); |
| 90 | } | 90 | } |
| 91 | 91 | ||
| 92 | // Returns true if and only if storage allocated from *this | 92 | // Returns true if and only if storage allocated from *this |
| 93 | // can be deallocated from other, and vice versa. | 93 | // can be deallocated from other, and vice versa. |
| 94 | // Always returns true for stateless allocators. | 94 | // Always returns true for stateless allocators. |
| 95 | bool operator==(const AlignmentAllocator<T, Align>& other) const { | 95 | bool operator==(const AlignmentAllocator<T, Align>& other) const noexcept { |
| 96 | return true; | 96 | return true; |
| 97 | } | 97 | } |
| 98 | }; | 98 | }; |