internal/core/export: avoid introducing shadowing
The solution is to unconditionally link Ident.Node fields with
their resolution, allowing the sanitizer to unshadow.
The exporter is becoming quite a mess and is due for an
overhaul. The implementation should be notably easier with the
upcoming evaluator overhaul, so it seems a waste to do that now.
Fixes #2311
Signed-off-by: Marcel van Lohuizen <mpvl@gmail.com>
Change-Id: I38d2c010814e5d97424d72890da002bb1c6ef2cb
Reviewed-on: https://review.gerrithub.io/c/cue-lang/cue/+/552252
Reviewed-by: Roger Peppe <rogpeppe@gmail.com>
Unity-Result: CUEcueckoo <cueckoo@cuelang.org>
TryBot-Result: CUEcueckoo <cueckoo@cuelang.org>