diff options
author | karpik <karpik@yandex-team.ru> | 2022-02-10 16:49:23 +0300 |
---|---|---|
committer | Daniil Cherednik <dcherednik@yandex-team.ru> | 2022-02-10 16:49:23 +0300 |
commit | 9cb2cb2fdceae44848ab4504f5e445015b0eca6e (patch) | |
tree | 3a0eb3ce001feaa01c007e7845c304fbafeeca9f /util | |
parent | 4413723d359117d4e6287d7ba94ee9b4102fa149 (diff) | |
download | ydb-9cb2cb2fdceae44848ab4504f5e445015b0eca6e.tar.gz |
Restoring authorship annotation for <karpik@yandex-team.ru>. Commit 1 of 2.
Diffstat (limited to 'util')
-rw-r--r-- | util/generic/guid.cpp | 2 | ||||
-rw-r--r-- | util/generic/guid.h | 10 |
2 files changed, 6 insertions, 6 deletions
diff --git a/util/generic/guid.cpp b/util/generic/guid.cpp index 8b907457bc..1225c0f44a 100644 --- a/util/generic/guid.cpp +++ b/util/generic/guid.cpp @@ -7,7 +7,7 @@ #include <util/stream/format.h> #include <util/system/unaligned_mem.h> #include <util/random/easy.h> - + namespace { inline void LowerCaseHex(TString& s) { for (auto&& c : s) { diff --git a/util/generic/guid.h b/util/generic/guid.h index 2bf6c8ad99..94557e6f99 100644 --- a/util/generic/guid.h +++ b/util/generic/guid.h @@ -1,5 +1,5 @@ -#pragma once - +#pragma once + #include "fwd.h" #include <util/str_stl.h> @@ -16,7 +16,7 @@ */ struct TGUID { ui32 dw[4] = {}; - + constexpr bool IsEmpty() const noexcept { return (dw[0] | dw[1] | dw[2] | dw[3]) == 0; } @@ -42,7 +42,7 @@ struct TGUID { * https://datatracker.ietf.org/doc/html/rfc4122#section-4.1 **/ static TGUID CreateTimebased(); -}; +}; constexpr bool operator==(const TGUID& a, const TGUID& b) noexcept { return a.dw[0] == b.dw[0] && a.dw[1] == b.dw[1] && a.dw[2] == b.dw[2] && a.dw[3] == b.dw[3]; @@ -56,7 +56,7 @@ struct TGUIDHash { constexpr int operator()(const TGUID& a) const noexcept { return a.dw[0] + a.dw[1] + a.dw[2] + a.dw[3]; } -}; +}; template <> struct THash<TGUID> { |