summaryrefslogtreecommitdiff
path: root/src/value.hh
diff options
context:
space:
mode:
authorMaxime Coste <mawww@kakoune.org>2025-07-08 11:43:17 +1000
committerMaxime Coste <mawww@kakoune.org>2025-07-08 12:07:33 +1000
commitce1d512a0c1922ab5f43f28e7bae573508c98601 (patch)
tree7af8effd6b00c304cda1c87f657a0014fcdae2ae /src/value.hh
parentfea08fc18d268ace4f843ec2b57cc33e36562098 (diff)
Replace std::unique_ptr with a custom implementation
<memory> is a costly header we can avoid by just implementing UniquePtr ourselves, which is a pretty straightforward in modern C++, this saves around 10% of the compilation time here.
Diffstat (limited to 'src/value.hh')
-rw-r--r--src/value.hh4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/value.hh b/src/value.hh
index f38e4fa2..0895927b 100644
--- a/src/value.hh
+++ b/src/value.hh
@@ -3,9 +3,9 @@
#include "hash_map.hh"
#include "meta.hh"
+#include "unique_ptr.hh"
#include <type_traits>
-#include <memory>
namespace Kakoune
{
@@ -68,7 +68,7 @@ private:
T m_content;
};
- std::unique_ptr<Concept> m_value;
+ UniquePtr<Concept> m_value;
};
enum class ValueId : int {};