From 591a321f47745932b93cdf34ec92c020e58a7c0c Mon Sep 17 00:00:00 2001 From: Danny Robson Date: Thu, 4 Oct 2018 14:53:21 +1000 Subject: [PATCH] alloc/arena: forward reset calls to underlying store of owned arena --- alloc/arena.hpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/alloc/arena.hpp b/alloc/arena.hpp index 15a58f1d..fd3a3a2e 100644 --- a/alloc/arena.hpp +++ b/alloc/arena.hpp @@ -75,7 +75,6 @@ namespace cruft::alloc { }; } - private: T &m_store; }; @@ -112,6 +111,10 @@ namespace cruft::alloc { decltype(auto) unique (ArgsT &&...args) { return m_arena.template unique (std::forward (args)...); } + template + decltype(auto) reset (Args&&...args) + { return m_store.reset (std::forward (args)...); } + private: AllocT m_store; arena m_arena;