From 45a756a6a0e464fc70d0de27cc46374436d77a0a Mon Sep 17 00:00:00 2001 From: dzaima Date: Wed, 28 May 2025 04:21:21 +0300 Subject: [PATCH] =?UTF-8?q?fix=20reference=20leak=20on=20heapAllocatedAtom?= =?UTF-8?q?=E2=8A=B8=C2=BB=CB=980=E2=80=BF2=E2=A5=8A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit caught by test/cells.bqn --- src/builtins/cells.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/builtins/cells.c b/src/builtins/cells.c index 2d149399..4cec6758 100644 --- a/src/builtins/cells.c +++ b/src/builtins/cells.c @@ -765,7 +765,10 @@ NOINLINE B for_cells_SA(B f, B w, B x, ur xcr, ur xr, u32 chr) { // w⊸F⎉xcr if (xcr!=1) break; if (isAtm(w)) { shift_atm:; - if (IA(x)==0) return x; + if (IA(x)==0) { + dec(w); + return x; + } return shift_cells(w, x, cam, xsh[xk], el_or(TI(x,elType), selfElType(w)), rtid); } if (RNK(w)==0) {