hslua-aeson

Allow aeson data types to be used with lua.

https://github.com/tarleb/hslua-aeson#readme

Version on this page:2.0.1
LTS Haskell 22.17:2.3.1
Stackage Nightly 2024-04-18:2.3.1
Latest on Hackage:2.3.1

See all snapshots hslua-aeson appears in

MIT licensed by Albert Krewinkel
Maintained by Albert Krewinkel
This version can be pinned in stack with:hslua-aeson-2.0.1@sha256:2b3db325c1922b814efece9be6f8c3044a7da0ab86e66489aad96690d8f4edb3,3189

Module documentation for 2.0.1

hslua-aeson

travis build status MIT License

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 a special value (stored in the registry field HSLUA_AESON_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.

  • JSON numbers are converted to Lua numbers (usually doubles), which can cause a loss of precision.

License

This project is licensed under the liberal MIT license, the same license under which hslua and lua itself are published. See the LICENSE file for details.

Changes

Changelog

hslua-aeson uses PVP Versioning.

hslua-aeson-2.0.1

Released 2021-12-28.

  • Restored compatibility with aeson 1.5.

hslua-aeson-2.0.0

Released 2021-12-17.

  • Changed module name from Foreign.Lua.Aeson to HsLua.Aeson.

  • The Peekable and Pushable instances have been removed. The package no longer defines orphaned instances.

  • Updated hslua and aeson to the respective 2.0 version.

hslua-aeson-1.0.3.1

Released 2020-10-16.

  • Allow hslua-1.3.*.

hslua-aeson-1.0.3

Released 2020-08-15.

  • Relaxed version constraint for hslua, allowing hslua-1.2.*.

hslua-aeson-1.0.2

Released 2020-05-28

  • Relaxed version constraint for aeson, allowing aeson-1.5.*.

  • Update CI tests to check with GHC versions 8.0 through 8.10. Compilation with GHC 7.10 is no longer tested.

  • Bump to stackage LTS-14.

hslua-aeson-1.0.1

Released 2020-04-03

  • Relax version constraint for packages hashable and hslua, allow hashable-1.3 and hslua-1.1.*.

hslua-aeson-1.0.0

Released 2019-09-24.

  • Update to hslua 1.0.0

  • Function registerNull has been replaced by pushNull.

    Using pushNull has the advantage that users won’t have to remember to register a special variable. Users who need a global variable can set it by running

      pushNull
      setglobal "HSLUA_AESON_NULL"
    

hslua-aeson-0.3.0

Released 2017-08-18.

  • Update to hslua 0.8.0.

hslua-aeson-0.2.0

Not publicly released.

  • Update to hslua 0.6.0.

hslua-aeson-0.1.0.4

Released 2017-04-17.

  • Ensure compatibility with hslua 0.5.0.

hslua-aeson-0.1.0.0

Released 2017-02-03.

  • Initial release.