Fix compiler warnings.

Reported by gan74.
This commit is contained in:
Mike Pall
2022-09-13 13:43:03 +02:00
parent d13610a845
commit fffd3eafc4
3 changed files with 7 additions and 7 deletions

View File

@@ -1117,7 +1117,7 @@ static LJ_AINLINE TRef recff_sbufx_len(jit_State *J, TRef trr, TRef trw)
}
/* Emit typecheck for string buffer. */
static TRef recff_sbufx_check(jit_State *J, RecordFFData *rd, int arg)
static TRef recff_sbufx_check(jit_State *J, RecordFFData *rd, ptrdiff_t arg)
{
TRef trtype, ud = J->base[arg];
if (!tvisbuf(&rd->argv[arg])) lj_trace_err(J, LJ_TRERR_BADTYPE);
@@ -1135,7 +1135,7 @@ static TRef recff_sbufx_write(jit_State *J, TRef ud)
}
/* Check for integer in range for the buffer API. */
static TRef recff_sbufx_checkint(jit_State *J, RecordFFData *rd, int arg)
static TRef recff_sbufx_checkint(jit_State *J, RecordFFData *rd, ptrdiff_t arg)
{
TRef tr = J->base[arg];
TRef trlim = lj_ir_kint(J, LJ_MAX_BUF);