mirror of
https://github.com/LuaJIT/LuaJIT.git
synced 2025-04-16 12:19:19 +00:00
Compare commits
3 Commits
538a82133a
...
e0a7ea8a92
Author | SHA1 | Date | |
---|---|---|---|
![]() |
e0a7ea8a92 | ||
![]() |
e76bb50d44 | ||
![]() |
e9e4b6d302 |
@ -122,8 +122,9 @@ LUALIB_API int luaL_loadfilex(lua_State *L, const char *filename,
|
||||
copyTV(L, L->top-1, L->top);
|
||||
}
|
||||
if (err) {
|
||||
const char *fname = filename ? filename : "stdin";
|
||||
L->top--;
|
||||
lua_pushfstring(L, "cannot read %s: %s", chunkname+1, strerror(err));
|
||||
lua_pushfstring(L, "cannot read %s: %s", fname, strerror(err));
|
||||
return LUA_ERRFILE;
|
||||
}
|
||||
return status;
|
||||
|
@ -1107,7 +1107,10 @@ int lj_record_mm_lookup(jit_State *J, RecordIndex *ix, MMS mm)
|
||||
return 0; /* No metamethod. */
|
||||
}
|
||||
/* The cdata metatable is treated as immutable. */
|
||||
if (LJ_HASFFI && tref_iscdata(ix->tab)) goto immutable_mt;
|
||||
if (LJ_HASFFI && tref_iscdata(ix->tab)) {
|
||||
mix.tab = TREF_NIL;
|
||||
goto immutable_mt;
|
||||
}
|
||||
ix->mt = mix.tab = lj_ir_ggfload(J, IRT_TAB,
|
||||
GG_OFS(g.gcroot[GCROOT_BASEMT+itypemap(&ix->tabv)]));
|
||||
goto nocheck;
|
||||
|
Loading…
Reference in New Issue
Block a user