From 0907458b4dc4226c143a9c933b9d10d4a10225ea Mon Sep 17 00:00:00 2001 From: dzaima Date: Sun, 1 May 2022 02:34:47 +0300 Subject: [PATCH] =?UTF-8?q?allow=20c32=20to=20use=20i32=20path=20in=20?= =?UTF-8?q?=E2=8D=8B=F0=9D=95=A9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/builtins/grade.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/builtins/grade.h b/src/builtins/grade.h index 6ca13500..628c51ac 100644 --- a/src/builtins/grade.h +++ b/src/builtins/grade.h @@ -46,8 +46,8 @@ B GRADE_CAT(c1)(B t, B x) { TFREE(tmp); decG(x); return r; } - if (xe==el_i32) { - i32* xp = i32any_ptr(x); + if (xe==el_i32 || xe==el_c32) { // safe to use the same comparison for i32 & c32 as c32 is 0≤x≤1114111 + i32* xp = tyany_ptr(x); i32 min=I32_MAX, max=I32_MIN; for (usz i = 0; i < ia; i++) { i32 c = xp[i];