-
Notifications
You must be signed in to change notification settings - Fork 302
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
internal/core/adt: remove further evaluatingArcs logic
The logic is now only used for detecting "mutual dependencies". This construct resulted in spurious cycle detections, which caused builtins to remain unevaluated. To make this work, we now copy the "postChecks logic of the old evaluator. This harmonizes error messages in circular dependencies in comprehensions. Note that before we only conversed over each arc of a node once (using arcPos). However, this prevents us from detecting structural cycles if a node was shared now that the evaluatingArcs is moreved. We therefore removed this logic. We still use an index, instead of range in case an arc is added later. Fixes various tests, including one counter test. Previously, when comparing to bottom, Finalize might be called recursively. This caused a node to be finalized while comprehensions were running, resulting in a mismatch of counters. Signed-off-by: Marcel van Lohuizen <mpvl@gmail.com> Change-Id: I907e528894abd154eef685199cf5681230a222c8 Reviewed-on: https://review.gerrithub.io/c/cue-lang/cue/+/1202837 Reviewed-by: Daniel Martí <mvdan@mvdan.cc> TryBot-Result: CUEcueckoo <cueckoo@cuelang.org> Unity-Result: CUE porcuepine <cue.porcuepine@gmail.com>
- Loading branch information
Showing
9 changed files
with
168 additions
and
503 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.