From ce1d512a0c1922ab5f43f28e7bae573508c98601 Mon Sep 17 00:00:00 2001 From: Maxime Coste Date: Tue, 8 Jul 2025 11:43:17 +1000 Subject: Replace std::unique_ptr with a custom implementation 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. --- src/diff.hh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/diff.hh') diff --git a/src/diff.hh b/src/diff.hh index 2f582b16..bcca655a 100644 --- a/src/diff.hh +++ b/src/diff.hh @@ -7,7 +7,7 @@ #include #include -#include +#include "unique_ptr.hh" namespace Kakoune { @@ -175,7 +175,7 @@ template data(new int[2*max]); + UniquePtr data(new int[2*max]); constexpr int cost_limit = 1000; Diff last{}; -- cgit v1.2.3