From 263bbc88cf1b9423054cdbdbcdd9f31366184920 Mon Sep 17 00:00:00 2001 From: Brett Date: Sun, 10 Mar 2024 22:57:40 -0400 Subject: [PATCH] fix not calling the destructor --- CMakeLists.txt | 2 +- include/blt/std/allocator.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index ad1ceaa..ad45dcd 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,7 +1,7 @@ cmake_minimum_required(VERSION 3.5) include(cmake/color.cmake) -set(BLT_VERSION 0.14.10) +set(BLT_VERSION 0.14.11) set(BLT_TEST_VERSION 0.0.1) set(BLT_TARGET BLT) diff --git a/include/blt/std/allocator.h b/include/blt/std/allocator.h index ede749e..3488d7f 100644 --- a/include/blt/std/allocator.h +++ b/include/blt/std/allocator.h @@ -878,7 +878,7 @@ namespace blt template inline void destroy(U* p) { - if constexpr (std::is_trivially_destructible_v) + if constexpr (!std::is_trivially_destructible_v) { if (p != nullptr) p->~U();