1
0
mirror of https://github.com/TomHarte/CLK.git synced 2025-04-06 10:38:16 +00:00

Improve alignment for all RegisterPairs.

This commit is contained in:
Thomas Harte 2022-09-26 13:28:41 -04:00
parent 3455f6393a
commit 02638b7963

View File

@ -19,7 +19,7 @@
namespace CPU {
/// Provides access to all intermediate parts of a larger int.
template <typename Full, typename Half> union RegisterPair {
template <typename Full, typename Half> union alignas(alignof(Full)) RegisterPair {
RegisterPair(Full v) : full(v) {}
RegisterPair() {}