diff options
| author | Maxime Coste <frrrwww@gmail.com> | 2015-06-26 21:32:37 +0100 |
|---|---|---|
| committer | Maxime Coste <frrrwww@gmail.com> | 2015-06-26 21:32:37 +0100 |
| commit | 1170277e91490f455d9727fa29c38d60c710151b (patch) | |
| tree | df2aa6c61a596427e8b797856db735bc5abd9b6f /src/memory.hh | |
| parent | 1af82e2e24779e863a41fc7bc68bcf5f0f197e8e (diff) | |
Always inline Allocator::construct/destroy
Diffstat (limited to 'src/memory.hh')
| -rw-r--r-- | src/memory.hh | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/memory.hh b/src/memory.hh index a31e83c9..fb36b3e7 100644 --- a/src/memory.hh +++ b/src/memory.hh @@ -112,12 +112,14 @@ struct Allocator } template<class U, class... Args> + [[gnu::always_inline]] void construct(U* p, Args&&... args) { new ((void*)p) U(std::forward<Args>(args)...); } template<class U> + [[gnu::always_inline]] void destroy(U* p) { p->~U(); } }; |
