meta_any: replace ::owner (never released yet) with ::base

This commit is contained in:
Michele Caini
2024-11-05 12:16:53 +01:00
parent 0181c2c604
commit 0c5ca2f544
2 changed files with 15 additions and 12 deletions

View File

@@ -591,11 +591,6 @@ public:
return meta_any{*this, storage.as_ref()};
}
/*! @copydoc any::owner */
[[nodiscard]] bool owner() const noexcept {
return storage.owner();
}
/**
* @brief Returns the current mode of a meta any object.
* @return The current mode of the meta any object.
@@ -604,6 +599,14 @@ public:
return storage.policy();
}
/**
* @brief Returns the underlying storage.
* @return The underlyig storage.
*/
[[nodiscard]] const any &base() const noexcept {
return storage;
}
private:
any storage{};
const meta_ctx *ctx{&locator<meta_ctx>::value_or()};