From baddf60a4ee079f2e35141366f9c1ad7e7308875 Mon Sep 17 00:00:00 2001 From: william Date: Fri, 19 Sep 2014 20:06:23 -0700 Subject: unbreak Lua 5.1 build --- src/compat52.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src') diff --git a/src/compat52.h b/src/compat52.h index 96ec9b2..e64edd9 100644 --- a/src/compat52.h +++ b/src/compat52.h @@ -149,4 +149,12 @@ typedef struct luaL_Stream { #define lua_rawlen(...) lua_objlen(__VA_ARGS__) +#define lua_pushstring(...) lua52_pushstring(__VA_ARGS__) + +static const char *lua52_pushstring(lua_State *L, const char *s) { + lua_pushstring(L, s); + return lua_tostring(L, -1); +} /* lua52_pushstring() */ + + #endif /* LUA_VERSION_NUM < 502 */ -- cgit v1.2.3-59-g8ed1b