mirror of
https://github.com/pocketpy/pocketpy
synced 2025-10-20 19:40:18 +00:00
some fix
This commit is contained in:
parent
1f4b72e010
commit
df5f5b4e93
@ -151,7 +151,6 @@ inline bool is_type(PyObject* obj, Type type) {
|
|||||||
#endif
|
#endif
|
||||||
switch(type.index){
|
switch(type.index){
|
||||||
case kTpIntIndex: return is_int(obj);
|
case kTpIntIndex: return is_int(obj);
|
||||||
case kTpFloatIndex: return is_float(obj);
|
|
||||||
default: return !is_tagged(obj) && obj->type == type;
|
default: return !is_tagged(obj) && obj->type == type;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -367,8 +367,7 @@ public:
|
|||||||
|
|
||||||
Type _tp(PyObject* obj){
|
Type _tp(PyObject* obj){
|
||||||
if(!is_tagged(obj)) return obj->type;
|
if(!is_tagged(obj)) return obj->type;
|
||||||
if(is_int(obj)) return tp_int;
|
return tp_int;
|
||||||
return tp_float;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
PyObject* _t(PyObject* obj){
|
PyObject* _t(PyObject* obj){
|
||||||
|
Loading…
x
Reference in New Issue
Block a user