this repo has no description
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

internal/core/adt: remove unused nodeContext fields

Remove dynamicFields and buffer fields from nodeContext
that were only cleared but never actually used. Also
remove the envDynamic type that was only referenced by
the unused dynamicFields field.

Signed-off-by: Marcel van Lohuizen <mpvl@gmail.com>
Change-Id: I6c91b6bfb320bf45c2afea52a76ccedc1c406237
Reviewed-on: https://review.gerrithub.io/c/cue-lang/cue/+/1220007
TryBot-Result: CUEcueckoo <cueckoo@cuelang.org>
Unity-Result: CUE porcuepine <cue.porcuepine@gmail.com>
Reviewed-by: Daniel Martí <mvdan@mvdan.cc>

-24
-24
internal/core/adt/eval.go
··· 324 324 conjuncts []conjunct 325 325 cyclicConjuncts []cyclicConjunct 326 326 327 - dynamicFields []envDynamic 328 - 329 327 // These fields are used to track type checking. 330 328 reqDefIDs []refInfo 331 329 replaceIDs []replaceID ··· 347 345 // disjuncts holds disjuncts that evaluated to a non-bottom value. 348 346 // TODO: come up with a better name. 349 347 disjuncts []*nodeContext 350 - buffer []*nodeContext 351 348 disjunctErrs []*Bottom 352 349 353 350 // hasDisjunction marks wither any disjunct was added. It is listed here 354 351 // instead of in nodeContextState as it should be cleared when a disjunction 355 352 // is split off. TODO: find something more principled. 356 353 hasDisjunction bool 357 - 358 - // snapshot holds the last value of the vertex before calling postDisjunct. 359 - snapshot *Vertex 360 - 361 - // Result holds the last evaluated value of the vertex after calling 362 - // postDisjunct. 363 - result *Vertex 364 354 } 365 355 366 356 type conjunct struct { ··· 546 536 sharedIDs: n.sharedIDs[:0], 547 537 checks: n.checks[:0], 548 538 postChecks: n.postChecks[:0], 549 - dynamicFields: n.dynamicFields[:0], 550 539 reqDefIDs: n.reqDefIDs[:0], 551 540 replaceIDs: n.replaceIDs[:0], 552 541 conjunctInfo: n.conjunctInfo[:0], ··· 554 543 disjunctions: n.disjunctions[:0], 555 544 disjunctErrs: n.disjunctErrs[:0], 556 545 disjuncts: n.disjuncts[:0], 557 - buffer: n.buffer[:0], 558 546 } 559 547 n.scheduler.clear() 560 548 } else { ··· 784 772 } 785 773 786 774 return v 787 - } 788 - 789 - type envExpr struct { 790 - c Conjunct 791 - err *Bottom 792 - } 793 - 794 - type envDynamic struct { 795 - env *Environment 796 - field *DynamicField 797 - id CloseInfo 798 - err *Bottom 799 775 } 800 776 801 777 type envCheck struct {