aboutsummaryrefslogtreecommitdiffstats
path: root/util/generic/lazy_value.h
diff options
context:
space:
mode:
authorswarmer <swarmer@yandex-team.com>2024-08-08 00:09:27 +0300
committerswarmer <swarmer@yandex-team.com>2024-08-08 00:41:56 +0300
commitf6bef9fbea60ca539cc741158e4762ff1b949e69 (patch)
treeea821fe798e13c8b39715347911928a5b1a63081 /util/generic/lazy_value.h
parent38cff6773bff060c5772a03ad45f5d4b6ef8afe1 (diff)
downloadydb-f6bef9fbea60ca539cc741158e4762ff1b949e69.tar.gz
check the lifetime bounds of the explicit_type, the lazy_value, and the queue containers
5f83506ef4fb80da806490df993e39a22d6c010a
Diffstat (limited to 'util/generic/lazy_value.h')
-rw-r--r--util/generic/lazy_value.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/util/generic/lazy_value.h b/util/generic/lazy_value.h
index e54cdb31d0..8dd53b763d 100644
--- a/util/generic/lazy_value.h
+++ b/util/generic/lazy_value.h
@@ -19,18 +19,18 @@ public:
return ValueHolder.Defined();
}
- const T& GetRef() const {
+ const T& GetRef() const Y_LIFETIME_BOUND {
if (!WasLazilyInitialized()) {
InitDefault();
}
return *ValueHolder;
}
- const T& operator*() const {
+ const T& operator*() const Y_LIFETIME_BOUND {
return GetRef();
}
- const T* operator->() const {
+ const T* operator->() const Y_LIFETIME_BOUND {
return &GetRef();
}