From d578536e310e2d0b1bb81ba7b0fb086213eed59c Mon Sep 17 00:00:00 2001 From: Steven Schveighoffer Date: Wed, 8 Mar 2023 16:34:09 -0500 Subject: [PATCH] Fix #87 --- source/iopipe/refc.d | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/iopipe/refc.d b/source/iopipe/refc.d index 70bcc5c..ef736d1 100644 --- a/source/iopipe/refc.d +++ b/source/iopipe/refc.d @@ -84,7 +84,7 @@ struct RefCounted(T) { if(_impl) { - assert(_impl._count >= 0, "Invalid count detected"); + assert(_impl._count > 0, "Invalid count detected"); import core.atomic; if(_impl._count.atomicOp!"-="(1) == 0) {