1<section xmlns="http://docbook.org/ns/docbook"
2 xmlns:xlink="http://www.w3.org/1999/xlink"
3 xmlns:xi="http://www.w3.org/2001/XInclude"
4 xml:id="sec-debug">
5 <title>Debugging Nix Expressions</title>
6
7 <para>
8 Nix is a unityped, dynamic language, this means every value can potentially
9 appear anywhere. Since it is also non-strict, evaluation order and what
10 ultimately is evaluated might surprise you. Therefore it is important to be
11 able to debug nix expressions.
12 </para>
13
14 <para>
15 In the <literal>lib/debug.nix</literal> file you will find a number of
16 functions that help (pretty-)printing values while evaluation is runnnig. You
17 can even specify how deep these values should be printed recursively, and
18 transform them on the fly. Please consult the docstrings in
19 <literal>lib/debug.nix</literal> for usage information.
20 </para>
21</section>