about summary refs log tree commit diff
path: root/tests/lang/eval-okay-dynamic-attrs-2.nix
diff options
context:
space:
mode:
authorShea Levy <shea@shealevy.com>2013-12-31T22·57-0500
committerShea Levy <shea@shealevy.com>2013-12-31T22·57-0500
commit6f3a51809a2603574a16573bd46b95e4ff5233bd (patch)
tree5b840b6156d4eff11781e2c12258f36fd4fddac5 /tests/lang/eval-okay-dynamic-attrs-2.nix
parent18fefacf7df570444b332a8a0c2dc4f9d98d4344 (diff)
Fold dynamic binds handling into addAttr
Since addAttr has to iterate through the AttrPath we pass it, it makes
more sense to just iterate through the AttrNames in addAttr instead. As
an added bonus, this allows attrsets where two dynamic attribute paths
have the same static leading part (see added test case for an example
that failed previously).

Signed-off-by: Shea Levy <shea@shealevy.com>
Diffstat (limited to 'tests/lang/eval-okay-dynamic-attrs-2.nix')
-rw-r--r--tests/lang/eval-okay-dynamic-attrs-2.nix1
1 files changed, 1 insertions, 0 deletions
diff --git a/tests/lang/eval-okay-dynamic-attrs-2.nix b/tests/lang/eval-okay-dynamic-attrs-2.nix
new file mode 100644
index 000000000000..6d57bf854908
--- /dev/null
+++ b/tests/lang/eval-okay-dynamic-attrs-2.nix
@@ -0,0 +1 @@
+{ a."${"b"}" = true; a."${"c"}" = false; }.a.b