!avYyleMexqjFHoqrME:nixos.org

Nix Documentation

438 Members
Discussion about documentation improvements around the Nix ecosystem94 Servers

You have reached the beginning of time (for this room).


SenderMessageTime
17 Jan 2024
@mightyiam:matrix.org@mightyiam:matrix.org

Expression example example:

```nix
null
```

If it evaluates into null then it's good. If it evaluates into anything else it's bad. If it fails to evaluate, it's bad. The idea is that the author will use Nix assertions to prove their points in the example.

12:13:49
@mightyiam:matrix.org@mightyiam:matrix.orgFor the expression example, we can think of a future feature where the expression is a function that will be called with a scope.12:16:05
@mightyiam:matrix.org@mightyiam:matrix.orgThe usage of assertions in examples is inspired by Rust doctests.12:18:23
@bzzm3r:matrix.org@bzzm3r:matrix.org
In reply to @mightyiam:matrix.org
Sorry, there's no documentation. There are tests for the repl examples and there are tests for the WIP expression examples.
https://github.com/mobusoperandi/eelco/tree/0eb9042220befe188aa4399ffc6615579cebdd5f/crates/eelco/tests
How does a user specify input? What kind of output does does a doc tester produce? Would you find it useful to co-opt the language/structure in the issue linked above, or does it pose unnecessary constraints on your work?
12:22:53

Show newer messages


Back to Room ListRoom Version: 6