packages feed

pbc4hs 0.1.1.4 → 0.1.1.5

raw patch · 4 files changed

+13/−5 lines, 4 files

Files

Changelog view
@@ -1,3 +1,10 @@+2014-02-25  David Feng <davidxifeng@gmail.com>++             * cbits/pbc-lua.c: (bugfix) revert last commit to fix the bug++             * src/Scripting/Lua/Pbc.hs: (bugfix) call c_luaopen_pbc with cpcall++ 2014-02-24  David Feng <davidxifeng@gmail.com>               * cbits/pbc-lua.c: add the missing lua_pop call after luaL_register
cbits/pbc-lua.c view
@@ -1093,7 +1093,6 @@  	luaL_checkversion(L); 	luaL_newlib(L, reg);-	lua_pop(L, 1);  	return 1; }
pbc4hs.cabal view
@@ -1,5 +1,5 @@ name:                pbc4hs-version:             0.1.1.4+version:             0.1.1.5 synopsis:            pbc for HsLua description:         pbc wrapper for HsLua license:             BSD3
src/Scripting/Lua/Pbc.hs view
@@ -10,17 +10,19 @@  import Scripting.Lua import Data.String.QQ+import Foreign+import Foreign.C -foreign import ccall "luaopen_protobuf_c" c_luaopen_pbc :: LuaState -> IO ()+foreign import ccall "&luaopen_protobuf_c" p_c_luaopen_pbc ::   FunPtr (LuaState -> IO CInt)  -- | open pbc Lua C binding library openPbc :: LuaState -> IO ()-openPbc = c_luaopen_pbc+openPbc l = cpcall l p_c_luaopen_pbc nullPtr >> return ()  -- | open pbc Lua library openLuaPbc :: LuaState -> IO () openLuaPbc l = do-    c_luaopen_pbc l+    openPbc l     loadstring l protobuf_lua "protobuf.lua"     call l 0 0