From 5f43bf16b3f3084dc5d7d26c88ed6890e688bc04 Mon Sep 17 00:00:00 2001 From: dzaima Date: Fri, 23 Jun 2023 11:54:21 +0300 Subject: [PATCH] add direct typed array type test macro --- src/h.h | 1 + 1 file changed, 1 insertion(+) diff --git a/src/h.h b/src/h.h index 59bdc4f8..605b32c1 100644 --- a/src/h.h +++ b/src/h.h @@ -283,6 +283,7 @@ enum Type { t_COUNT }; #define IS_ANY_ARR(T) ((T)>=t_hslice & (T)<=t_bitarr) +#define IS_DIRECT_TYARR(T) (((T)>=t_i8arr) & ((T)<=t_bitarr)) #define IS_SLICE(T) ((T)<=t_f64slice) #define TO_SLICE(T) ((T) + t_hslice - t_harr) // Assumes T!=t_bitarr