-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/
-- | Glue between aeson and hslua
--
-- Please see README.md
@package hslua-aeson
@version 0.1.0.0
-- | Glue to hslua for aeson values.
--
-- This provides a StackValue instance for aeson's
-- Value type. The following conventions are used:
--
--
-- - Null values are encoded as the special global
-- _NULL. Using Nil would cause problems with
-- null-containing arrays.
-- - Objects are converted to tables in a straight-forward way.
-- - Arrays are converted to lua tables. Array-length is included as
-- the value at index 0. This makes it possible to distinguish between
-- empty arrays and empty objects.
--
module Scripting.Lua.Aeson
-- | Create a new lua state suitable for use with aeson values. This
-- behaves like newstate in hslua, but initializes the
-- _NULL global. That variable is used to encode null values.
newstate :: IO LuaState
instance Scripting.Lua.StackValue Data.Scientific.Scientific
instance Scripting.Lua.StackValue Data.Text.Internal.Text
instance Scripting.Lua.StackValue a => Scripting.Lua.StackValue (Data.Vector.Vector a)
instance (GHC.Classes.Eq a, Data.Hashable.Class.Hashable a, Scripting.Lua.StackValue a, Scripting.Lua.StackValue b) => Scripting.Lua.StackValue (Data.HashMap.Base.HashMap a b)
instance Scripting.Lua.StackValue Data.Aeson.Types.Internal.Value