hslua-0.9.2: A Lua language interpreter embedding in Haskell

Copyright© 2007–2012 Gracjan Polak
2012–2016 Ömer Sinan Ağacan
2017 Albert Krewinkel
LicenseMIT
MaintainerAlbert Krewinkel <tarleb+hslua@zeitkraut.de>
Stabilitybeta
PortabilityForeignFunctionInterface
Safe HaskellNone
LanguageHaskell98

Foreign.Lua.Api.RawBindings

Contents

Description

Haskell bindings to lua C API functions.

Synopsis

State manipulation

Basic stack manipulation

Stack access functions

hslua_compare :: LuaState -> StackIndex -> StackIndex -> CInt -> IO (Failable LuaBool) Source #

Wrapper around -- @lua_compare@ which catches any longjmps.

Push functions

Get functions

hslua_gettable :: LuaState -> StackIndex -> IO CInt Source #

Wrapper around -- @lua_gettable@ which catches any longjmps.

hslua_getfield :: LuaState -> StackIndex -> Ptr CChar -> IO CInt Source #

Wrapper around -- @lua_getfield@ which catches any longjmps.

hslua_getglobal :: LuaState -> Ptr CChar -> IO CInt Source #

Wrapper around -- @lua_getglobal@ which catches any longjmps.

Set functions

hslua_settable :: LuaState -> StackIndex -> IO CInt Source #

Wrapper around -- @lua_settable@ which catches any longjmps.

hslua_setfield :: LuaState -> StackIndex -> Ptr CChar -> IO CInt Source #

Wrapper around -- @lua_setfield@ which catches any longjmps.

hslua_setglobal :: LuaState -> Ptr CChar -> IO CInt Source #

Wrapper around -- @lua_setglobal@ which catches any longjmps.

load and call functions (load and run Lua code)

Coroutine functions

Garbage-collection functions and options

Miscellaneous functions

hslua_next :: LuaState -> StackIndex -> IO (Failable LuaBool) Source #

Wrapper around -- @lua_next@ which catches any longjmps.

hslua_concat :: LuaState -> NumArgs -> IO (Failable LuaBool) Source #

Wrapper around -- @lua_concat@ which catches any longjmps.

Lua Libraries

lua_open_base_ptr :: CFunction Source #

Point to function opening the base library.

lua_open_table_ptr :: CFunction Source #

Point to function opening the table library.

lua_open_io_ptr :: CFunction Source #

Point to function opening the io library.

lua_open_os_ptr :: CFunction Source #

Point to function opening the os library.

lua_open_string_ptr :: CFunction Source #

Point to function opening the string library.

lua_open_math_ptr :: CFunction Source #

Point to function opening the math library.

lua_open_debug_ptr :: CFunction Source #

Point to function opening the debug library.

lua_open_package_ptr :: CFunction Source #

Point to function opening the package library.

The Auxiliary Library