summaryrefslogtreecommitdiffstats
path: root/util/generic/lazy_value.h
diff options
context:
space:
mode:
authortldr <[email protected]>2022-10-11 11:21:16 +0300
committertldr <[email protected]>2022-10-11 11:21:16 +0300
commit128195d32b1e2057a59cb74b66a2144f6d1e1853 (patch)
treeb0f784fa6283d7c4c64a54d0874d9e0f8aa0d144 /util/generic/lazy_value.h
parent184cd08ea40981258180039a6b3f40aed6e8caae (diff)
[util]TLazyValue: remove operator bool and Defined
Diffstat (limited to 'util/generic/lazy_value.h')
-rw-r--r--util/generic/lazy_value.h8
1 files changed, 2 insertions, 6 deletions
diff --git a/util/generic/lazy_value.h b/util/generic/lazy_value.h
index 3c720f76b5a..e54cdb31d0d 100644
--- a/util/generic/lazy_value.h
+++ b/util/generic/lazy_value.h
@@ -15,16 +15,12 @@ public:
{
}
- explicit operator bool() const noexcept {
- return Defined();
- }
-
- bool Defined() const noexcept {
+ bool WasLazilyInitialized() const noexcept {
return ValueHolder.Defined();
}
const T& GetRef() const {
- if (!Defined()) {
+ if (!WasLazilyInitialized()) {
InitDefault();
}
return *ValueHolder;