aboutsummaryrefslogtreecommitdiffstats
path: root/util/system/tls.h
diff options
context:
space:
mode:
authoriseg <iseg@yandex-team.ru>2022-02-10 16:49:39 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:49:39 +0300
commitf828a15ab90e9ca8e848f83caf95c95f06be46e7 (patch)
treede25241f7ec727b05ff1e5b9e1336f567f788a44 /util/system/tls.h
parent8124e2bb214b063687e0d77c900150c727e16782 (diff)
downloadydb-f828a15ab90e9ca8e848f83caf95c95f06be46e7.tar.gz
Restoring authorship annotation for <iseg@yandex-team.ru>. Commit 1 of 2.
Diffstat (limited to 'util/system/tls.h')
-rw-r--r--util/system/tls.h14
1 files changed, 7 insertions, 7 deletions
diff --git a/util/system/tls.h b/util/system/tls.h
index 3c4f56dbeb..17d58e3a0c 100644
--- a/util/system/tls.h
+++ b/util/system/tls.h
@@ -1,5 +1,5 @@
#pragma once
-
+
#include "defaults.h"
#include <util/generic/ptr.h>
@@ -176,7 +176,7 @@ namespace NTls {
}
};
- template <class T>
+ template <class T>
class TValue: public TMoveOnly {
class TConstructor {
public:
@@ -227,12 +227,12 @@ namespace NTls {
: Constructor_(new TCopyConstructor<T1>(value))
, Key_(Dtor)
{
- }
+ }
template <class T1>
inline T& operator=(const T1& val) {
return Get() = val;
- }
+ }
inline operator const T&() const {
return Get();
@@ -275,7 +275,7 @@ namespace NTls {
}
return val;
- }
+ }
private:
static void Dtor(void* ptr) {
@@ -283,12 +283,12 @@ namespace NTls {
((T*)ptr)->~T();
::NPrivate::FillWithTrash(ptr, sizeof(T));
- }
+ }
private:
THolder<TConstructor> Constructor_;
TKey Key_;
- };
+ };
}
template <class T>