cue: fix path representation for shared nodes
In some cases, paths referred to the shared
nodes, rather than the original. This was
caused by storing a too-early dereferenced
node in structValue. We now store the original
value, so that linkParent can correctly detect
when a node is shared.
Fixes #3922
Signed-off-by: Marcel van Lohuizen <mpvl@gmail.com>
Change-Id: Iea2bde18ce6c0879fb1254a2bb03da2eedcb28a3
Reviewed-on: https://review.gerrithub.io/c/cue-lang/cue/+/1215511
TryBot-Result: CUEcueckoo <cueckoo@cuelang.org>
Unity-Result: CUE porcuepine <cue.porcuepine@gmail.com>
Reviewed-by: Daniel Martí <mvdan@mvdan.cc>