Improve assertions.
This commit is contained in:
@@ -413,11 +413,12 @@ static LJ_AINLINE IRType itype2irt(const TValue *tv)
|
||||
|
||||
static LJ_AINLINE uint32_t irt_toitype_(IRType t)
|
||||
{
|
||||
lua_assert(!LJ_64 || LJ_GC64 || t != IRT_LIGHTUD);
|
||||
lj_assertX(!LJ_64 || LJ_GC64 || t != IRT_LIGHTUD,
|
||||
"no plain type tag for lightuserdata");
|
||||
if (LJ_DUALNUM && t > IRT_NUM) {
|
||||
return LJ_TISNUM;
|
||||
} else {
|
||||
lua_assert(t <= IRT_NUM);
|
||||
lj_assertX(t <= IRT_NUM, "no plain type tag for IR type %d", t);
|
||||
return ~(uint32_t)t;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user