From 35ef8b33d5c9286f8079d98716e88483011c8759 Mon Sep 17 00:00:00 2001 From: Guillaume Piolat Date: Thu, 12 Dec 2024 15:10:43 +0100 Subject: [PATCH] Disallow Vec!T with struct that have a non-trivial destructor (have a ~this) --- core/dplug/core/vec.d | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/dplug/core/vec.d b/core/dplug/core/vec.d index 3ed554d3..81fb05fd 100644 --- a/core/dplug/core/vec.d +++ b/core/dplug/core/vec.d @@ -368,7 +368,7 @@ nothrow: static if (is(T == struct) && hasElaborateDestructor!T) { - pragma(msg, "WARNING! struct with destructors were never meant to be supported in Vec!T. This will be removed in Dplug v15."); + static assert(false, "struct with destructors cannot go in `Vec!T`. You are welcome to use the `numem` package instead or do otherwise."); } public