Several libraries are already available with the standard Neko distribution. This document lists these libraries and also gives some guidelines about how to notate types for automatic documentation generation.
If you want to write your own libraries, have a look at the C FFI Documentation.
Here’s the notation of types that should be used when documenting libraries :
(is not up-to-date)
null, int, float, bool, string, array, object, function.any if any value is accepted.void can be used if the function is not supposed to return any meaningful value.number if both int and float are accepted.function:n if a function with n parameters is accepted.‘file is an abstract of kind file).int array is an array containing only integers and ‘file array array is a two dimensions array that contains abstract files.{ x ⇒ int, y ⇒ int } means an object having at least two fields x and y of type int.null value is accepted as well as some other ype, you can write, for example int?, which means int or null.number is actually a shortcut for int | float.#point = { x ⇒ int, y ⇒ int }. In the case you don’t define your type, the user of the library should not rely on its actual implementation since you can change it in the future.Please respect this type notation standard when documenting your Neko programs and libraries: it will help people using them.