From ecd981b1e1084cf03c1bc55b5825e1303dba9de4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=B6nke=20Ludwig?= Date: Mon, 30 Oct 2017 22:56:19 +0100 Subject: [PATCH] Fix compile error in internal API. --- source/vibe/internal/allocator.d | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/vibe/internal/allocator.d b/source/vibe/internal/allocator.d index d496aef..84027c2 100644 --- a/source/vibe/internal/allocator.d +++ b/source/vibe/internal/allocator.d @@ -26,7 +26,7 @@ auto makeGCSafe(T, Allocator, A...)(Allocator allocator, A args) static if (is (T == class)) enum tsize = __traits(classInstanceSize, T); else enum tsize = T.sizeof; static if (hasIndirections!T) - GC.addRange(cast(void*)ret, tsize, typeid(T)); + () @trusted { GC.addRange(cast(void*)ret, tsize, typeid(T)); } (); return ret; }