Add EncodeHex() and DecodeHex() to Redbean

This commit is contained in:
Justine Tunney 2023-07-06 15:38:08 -07:00
parent 00acd81b2f
commit a186143f62
No known key found for this signature in database
GPG key ID: BE714B4575D6E328
9 changed files with 97 additions and 13 deletions

View file

@ -27,11 +27,11 @@
*/
#define llex_c
#define LUA_CORE
#include "third_party/lua/llex.h"
#include "third_party/lua/lctype.h"
#include "third_party/lua/ldebug.h"
#include "third_party/lua/ldo.h"
#include "third_party/lua/lgc.h"
#include "third_party/lua/llex.h"
#include "third_party/lua/lobject.h"
#include "third_party/lua/lparser.h"
#include "third_party/lua/lprefix.h"

View file

@ -2020,6 +2020,12 @@ static int LuaUnixSchedYield(lua_State *L) {
return 0;
}
// unix.verynice()
static int LuaUnixVerynice(lua_State *L) {
verynice();
return 0;
}
////////////////////////////////////////////////////////////////////////////////
// unix.Stat object
@ -3338,6 +3344,7 @@ static const luaL_Reg kLuaUnix[] = {
{"unlink", LuaUnixUnlink}, // remove file
{"unveil", LuaUnixUnveil}, // filesystem sandboxing
{"utimensat", LuaUnixUtimensat}, // change access/modified time
{"verynice", LuaUnixVerynice}, // lowest priority
{"wait", LuaUnixWait}, // wait for child to change status
{"write", LuaUnixWrite}, // write to file or socket
{0}, //