diff options
| author | 2023-10-29 13:50:55 +0000 | |
|---|---|---|
| committer | 2024-01-24 04:26:55 +0000 | |
| commit | e4915fb7d2077584a11a15141bc81d28ed2b0125 (patch) | |
| tree | 1783055dc2e98eaf9099e8e7b194b55f8f607747 /src/common/uuid.h | |
| parent | Merge pull request #12678 from german77/settings_impl (diff) | |
| download | yuzu-e4915fb7d2077584a11a15141bc81d28ed2b0125.tar.gz yuzu-e4915fb7d2077584a11a15141bc81d28ed2b0125.tar.xz yuzu-e4915fb7d2077584a11a15141bc81d28ed2b0125.zip | |
Rework time service to fix time passing offline.
Diffstat (limited to 'src/common/uuid.h')
| -rw-r--r-- | src/common/uuid.h | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/src/common/uuid.h b/src/common/uuid.h index 7172ca165..81bfefbbb 100644 --- a/src/common/uuid.h +++ b/src/common/uuid.h | |||
| @@ -12,9 +12,8 @@ | |||
| 12 | namespace Common { | 12 | namespace Common { |
| 13 | 13 | ||
| 14 | struct UUID { | 14 | struct UUID { |
| 15 | std::array<u8, 0x10> uuid{}; | 15 | std::array<u8, 0x10> uuid; |
| 16 | 16 | ||
| 17 | /// Constructs an invalid UUID. | ||
| 18 | constexpr UUID() = default; | 17 | constexpr UUID() = default; |
| 19 | 18 | ||
| 20 | /// Constructs a UUID from a reference to a 128 bit array. | 19 | /// Constructs a UUID from a reference to a 128 bit array. |
| @@ -34,14 +33,6 @@ struct UUID { | |||
| 34 | */ | 33 | */ |
| 35 | explicit UUID(std::string_view uuid_string); | 34 | explicit UUID(std::string_view uuid_string); |
| 36 | 35 | ||
| 37 | ~UUID() = default; | ||
| 38 | |||
| 39 | constexpr UUID(const UUID&) noexcept = default; | ||
| 40 | constexpr UUID(UUID&&) noexcept = default; | ||
| 41 | |||
| 42 | constexpr UUID& operator=(const UUID&) noexcept = default; | ||
| 43 | constexpr UUID& operator=(UUID&&) noexcept = default; | ||
| 44 | |||
| 45 | /** | 36 | /** |
| 46 | * Returns whether the stored UUID is valid or not. | 37 | * Returns whether the stored UUID is valid or not. |
| 47 | * | 38 | * |
| @@ -121,6 +112,7 @@ struct UUID { | |||
| 121 | friend constexpr bool operator==(const UUID& lhs, const UUID& rhs) = default; | 112 | friend constexpr bool operator==(const UUID& lhs, const UUID& rhs) = default; |
| 122 | }; | 113 | }; |
| 123 | static_assert(sizeof(UUID) == 0x10, "UUID has incorrect size."); | 114 | static_assert(sizeof(UUID) == 0x10, "UUID has incorrect size."); |
| 115 | static_assert(std::is_trivial_v<UUID>); | ||
| 124 | 116 | ||
| 125 | /// An invalid UUID. This UUID has all its bytes set to 0. | 117 | /// An invalid UUID. This UUID has all its bytes set to 0. |
| 126 | constexpr UUID InvalidUUID = {}; | 118 | constexpr UUID InvalidUUID = {}; |