From 2b351cfee6e037d70c6b50177420a81b92764ce7 Mon Sep 17 00:00:00 2001 From: dzaima Date: Thu, 3 Jun 2021 20:12:39 +0300 Subject: [PATCH] fix c32arr-i32arr error checking --- src/builtins/arithd.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/builtins/arithd.c b/src/builtins/arithd.c index b3c0f86e..b9cee7c0 100644 --- a/src/builtins/arithd.c +++ b/src/builtins/arithd.c @@ -178,8 +178,7 @@ GC2i(sub, wv-xv, { dec(w); return r; } - if (isArr(x)) { - if (!eqShape(w, x)) thrF("-: Expected equal shape prefix (%H ≡ ≢𝕨, %H ≡ ≢𝕩)", w, x); + if (isArr(x) && eqShape(w, x)) { u32* wp = c32any_ptr(w); usz wia = a(w)->ia; if (TI(x).elType==el_i32) { u32* rp; B r = m_c32arrc(&rp, w);