top | item 32695488

(no title)

vdijkbas | 3 years ago

> This is why Nix is really just a front for bash. For all of its faults, at least bash is Turing-complete.

Nix is Turing-complete. This was even sometimes considered a problem because it makes the language too powerful:

https://nixos.org/~eelco/talks/guix-feb-2018.pdf

discuss

order

ghoward|3 years ago

This is news to me, I admit. But if this is true, then people shouldn't say Nix is declarative.

grumbel|3 years ago

This shouldn't really come as a surprise, any reasonably powerful language will end up Turing complete sooner or later, it's pretty difficult to avoid. Nix specifically doesn't even hide it, it has plain old function and recursion as primitives.

What makes it declarative is the lack of side effects and laziness.

throwamon|3 years ago

Although it's debatable, it's very common for functional languages to be categorized as declarative.