cuelang.org/go@v0.13.0/internal/core/dep/testdata/topcomprehension.txtar (about) 1 Test comprehensions that are defined above the reference root. 2 3 Because the references are not at addressable locations, the printed 4 references are bogus. However, this simply tests they are found, reported, 5 and do not cause a crash. 6 7 TODO: filter bogus references. 8 -- in.cue -- 9 for key, value in { test: 1 } { 10 ("a"): b: k1: key 11 ("a"): b: v1: value 12 a: b: k2: key 13 a: b: v2: value 14 } 15 a: { 16 for key, value in { test: 1 } { 17 ("b"): k3: key 18 ("b"): v3: value 19 b: k4: key 20 b: v4: value 21 } 22 b: {} 23 } 24 -- out/dependencies/field -- 25 line reference path of resulting vertex 26 -- out/dependencies/all -- 27 line reference path of resulting vertex 28 4: key => **non-rooted** 29 5: value => **non-rooted** 30 2: key => **non-rooted** 31 3: value => **non-rooted** 32 -- diff/dependencies/todo/p3 -- 33 Reordering. 34 -- out/dependencies/dynamic -- 35 line reference path of resulting vertex 36 4: key => **non-rooted** 37 5: value => **non-rooted** 38 11: key => **non-rooted** 39 12: value => **non-rooted** 40 2: key => **non-rooted** 41 3: value => **non-rooted** 42 9: key => **non-rooted** 43 10: value => **non-rooted**