You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Evaluation is indeed indispensable in the Nix language.
For example, #480 mentioned if we can provide some auto-completion for custom args:
{pkgs,root, ... }: # <- provide autocompletions for these args using the expression above
Case 2: #471 mentioned if we can provide completions for "selection"
{pkgs}:
{asdf=pkgs.asdf;}
Previously, nixd performed comprehensive evaluations, gathering insights into the values linked with each Abstract Syntax Tree (AST) node. This method facilitated the provision of language features like completion and diagnostics through real-time evaluations. However, the performance repercussions are significant. Each system-wide configuration evaluation takes several seconds to finalize, and users are obliged to specify the project's evaluation method, which is rather inconvenient.
However, the performance implications of full evaluation can severely hinder on-the-fly editing. So the challenge is:
How to incrementally evaluate the code? (In less than ms?)
How to discover the target automatically?
Ideas
"Incremental" processes invariably entail immutability. Hence, I've been pondering the prospect of introducing immutability to certain segments of the evaluation process. For instance, we could maintain the immutability of the evaluation results for all Nixpkgs. Perhaps the optimal solution lies in devising an evaluation system focused on individual files, while deferring resolution on external immutable values. But the question remains: how can we achieve this?
Value resolution regarding nix language
So what is the resolution then...
The text was updated successfully, but these errors were encountered:
Design Review
Motivation
Evaluation is indeed indispensable in the Nix language.
For example, #480 mentioned if we can provide some auto-completion for custom args:
Case 2: #471 mentioned if we can provide completions for "selection"
Previously, nixd performed comprehensive evaluations, gathering insights into the values linked with each Abstract Syntax Tree (AST) node. This method facilitated the provision of language features like completion and diagnostics through real-time evaluations. However, the performance repercussions are significant. Each system-wide configuration evaluation takes several seconds to finalize, and users are obliged to specify the project's evaluation method, which is rather inconvenient.
However, the performance implications of full evaluation can severely hinder on-the-fly editing. So the challenge is:
Ideas
"Incremental" processes invariably entail immutability. Hence, I've been pondering the prospect of introducing immutability to certain segments of the evaluation process. For instance, we could maintain the immutability of the evaluation results for all Nixpkgs. Perhaps the optimal solution lies in devising an evaluation system focused on individual files, while deferring resolution on external immutable values. But the question remains: how can we achieve this?
Value resolution regarding nix language
So what is the resolution then...
The text was updated successfully, but these errors were encountered: