aboutsummaryrefslogtreecommitdiffstats
path: root/nihil.generator/manual_lifetime.ccm
diff options
context:
space:
mode:
Diffstat (limited to 'nihil.generator/manual_lifetime.ccm')
-rw-r--r--nihil.generator/manual_lifetime.ccm6
1 files changed, 3 insertions, 3 deletions
diff --git a/nihil.generator/manual_lifetime.ccm b/nihil.generator/manual_lifetime.ccm
index 4a383ad..44bc0a8 100644
--- a/nihil.generator/manual_lifetime.ccm
+++ b/nihil.generator/manual_lifetime.ccm
@@ -64,14 +64,14 @@ private:
};
template <typename T>
-class manual_lifetime<T &> {
+struct manual_lifetime<T &> {
manual_lifetime() noexcept = default;
~manual_lifetime() = default;
auto construct(this manual_lifetime &self, T &value) noexcept -> T &
{
self.m_value = std::addressof(value);
- return self.m_value;
+ return value;
}
auto destruct(this manual_lifetime &) noexcept -> void
@@ -88,7 +88,7 @@ private:
};
template <typename T>
-class manual_lifetime<T &&> {
+struct manual_lifetime<T &&> {
manual_lifetime() noexcept = default;
~manual_lifetime() = default;