remove reference to builtins.langVersion

this is unrelated to the proposal, as the version declaration is only
relevant for parsing, and would cover all use cases of `langVersion` if
we have minor version numbers
This commit is contained in:
Valentin Gagarin 2023-06-22 14:09:52 +02:00
parent d54d6bc670
commit a64de1bfb2

View file

@ -281,32 +281,6 @@ Other discussions around language changes:
</details> </details>
1. `builtins.langVersion` returns the language version used for evaluating the given expression.
<details><summary>Arguments</summary>
- (+) Could make use of it for generating Nix expressions programmatically and annotating them with the correct version
- (+) `builtins.langVersion` is already part of the stable interface, this way we can make it pure
- (-) Requires maintaining more API surface without a clear use case
</details>
<details><summary>Alternatives</summary>
- Return the latest language version instead
- (-) Doesn't help to determine what is used for evaluating the current expression
- (+) Might provide opportunities for forward-compatible Nix code
- (-) Brittle and defeats the purpose of this RFC
- (-) Impure, the value depends on the environment
- Don't expose `builtins.langVersion` at all
- (+) No need to have this if the Nix files are versioned
- (+) `builtins.langVersion` is not documented and not widely used
</details>
1. Each time the language specification (currently as embodied by the Nix language evaluator) is changed, the language version must be incremented. 1. Each time the language specification (currently as embodied by the Nix language evaluator) is changed, the language version must be incremented.
<details><summary>Arguments</summary> <details><summary>Arguments</summary>