Popularity
5.4
Stable
Activity
6.7
-
5
4
2

Monthly Downloads: 265
Programming language: Haskell
License: MIT License
Tags: Scripting     Foreign     Hslua     DevOps    
Latest version: v1.0.3
Add another 'hslua' Package

README

hslua-aeson

travis build status [MIT License](./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](./LICENSE) file for details.


*Note that all licence references and agreements mentioned in the hslua-aeson README section above are relevant to that project's source code only.