HORIZON HASKELLDocslts/ghc-9.14.x45dd5372026-10-11Search names, modules, packages, or :: a typeCtrl K

GHC 9.14.1 · lts/ghc-9.14.x · 45dd537 · 2026-10-11

Modulehslua-objectorientation-2.5.0Haskell2010

HsLua.ObjectOrientation

This module provides types and functions to use Haskell values as userdata objects in Lua. These objects wrap a Haskell value and provide methods and properties to interact with the Haskell value.

The terminology in this module refers to the userdata values as /UD objects, and to their type as UD type/.

  • 1 type
  • 1 value
typetype UDType e fn a = UDTypeGeneric e fn a
#

A userdata type, capturing the behavior of Lua objects that wrap Haskell values. The type name must be unique; once the type has been used to push or retrieve a value, the behavior can no longer be modified through this type.

valuedeftypeGeneric
  1. :: Pusher e fn

    function pusher

  2. -> Name

    type name

  3. -> [(Operation, fn)]

    operations

  4. -> [Member e fn a]

    methods

  5. -> UDType e fn a
#

Defines a new type, defining the behavior of objects in Lua. Note that the type name must be unique.