1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-24 22:11:15 +02:00
nix/doc/manual/src/language/scope.md
Valentin Gagarin a713476790
docs: split types from syntax (#11013)
move together all syntactic and semantic information into one
page, and add a page on data types, which in turn links to the syntax and
semantics.

also split out the note on scoping rules into its own page.

Co-authored-by: Ryan Hendrickson <ryan.hendrickson@alum.mit.edu>
2024-07-03 09:03:41 +02:00

557 B

Scoping rules

Nix is statically scoped, but with multiple scopes and shadowing rules.

  • primary scope: explicitly-bound variables

  • secondary scope: implicitly-bound variables

Primary scope takes precedence over secondary scope. See with for a detailed example.