feat(profile): more Lua information

This commit is contained in:
phaneron 2026-04-15 13:55:03 -04:00
parent 1479e2f5a0
commit fcf5f9352a
10 changed files with 233 additions and 12 deletions

View file

@ -0,0 +1,25 @@
#ifndef LUA_ZIO_H
#define LUA_ZIO_H
DECLARE_STRUCT(Mbuffer);
DECLARE_STRUCT(Zio);
typedef Zio ZIO;
struct Mbuffer {
char* buffer;
size_t n;
size_t buffsize;
};
#include "lua/state.h"
#include "lua/types.h"
struct Zio {
size_t n; /* bytes still unread */
const char* p; /* current position in buffer */
lua_Reader reader;
void* data; /* additional data */
lua_State* L; /* Lua state (for reader) */
};
#endif