From f7eecaa1651bb0b3352600ad63f41efbd2099298 Mon Sep 17 00:00:00 2001 From: blueloveTH Date: Fri, 12 Apr 2024 15:50:34 +0800 Subject: [PATCH] Update obj.h --- include/pocketpy/obj.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/pocketpy/obj.h b/include/pocketpy/obj.h index 86c041cc..a1d5f8e7 100644 --- a/include/pocketpy/obj.h +++ b/include/pocketpy/obj.h @@ -149,7 +149,7 @@ inline bool is_type(PyObject* obj, Type type) { #if PK_DEBUG_EXTRA_CHECK if(obj == nullptr) throw std::runtime_error("is_type() called with nullptr"); #endif - return is_tagged(obj) ? type.index == kTpIntIndex : obj->type == type; + return is_small_int(obj) ? type.index == kTpIntIndex : obj->type == type; } [[deprecated("use is_type() instead")]]