From 3dba7b262827e4762a9cad8de9ac486ee9fd41a1 Mon Sep 17 00:00:00 2001 From: mertcandav Date: Mon, 9 Dec 2024 13:54:25 +0300 Subject: [PATCH] runtime: fix alive reference analysis of atomic reference counting --- std/runtime/rc.jule | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/std/runtime/rc.jule b/std/runtime/rc.jule index 7d325173..a8a53339 100644 --- a/std/runtime/rc.jule +++ b/std/runtime/rc.jule @@ -83,7 +83,7 @@ unsafe fn _RCDrop(mut p: _RCPtr): bool { unsafe fn _RCDropAtomic(mut p: _RCPtr): bool { // The atomicAdd function returns new data of pointer. // So if new data equals to zero, means references zeroed. - ret atomicAdd[_RCType](*p, -RCDelta, _RCMo) > RCDelta + ret atomicAdd[_RCType](*p, -RCDelta, _RCMo) >= RCDelta } // Deallocates reference counting data allocation.