diff options
Diffstat (limited to 'doc/manual/builtins.xml')
-rw-r--r-- | doc/manual/builtins.xml | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/doc/manual/builtins.xml b/doc/manual/builtins.xml index 3958297989a1..6a472291c363 100644 --- a/doc/manual/builtins.xml +++ b/doc/manual/builtins.xml @@ -750,6 +750,18 @@ in foo</programlisting> </varlistentry> + <varlistentry><term><function>builtins.toJSON</function> <replaceable>e</replaceable></term> + + <listitem><para>Return a string containing a JSON representation + of <replaceable>e</replaceable>. Strings, integers, booleans, + nulls and lists are mapped to their JSON equivalents. Sets + (except derivations) are represented as objects. Derivations are + translated to a JSON string containing the derivation’s output + path. Paths are copied to the store and represented as a JSON + string of the resulting store path.</para></listitem> + + </varlistentry> + <varlistentry><term><function>builtins.toPath</function> <replaceable>s</replaceable></term> <listitem><para>Convert the string value |