about summary refs log tree commit diff
path: root/tests/lang/eval-okay-with.nix
diff options
context:
space:
mode:
Diffstat (limited to 'tests/lang/eval-okay-with.nix')
-rw-r--r--tests/lang/eval-okay-with.nix19
1 files changed, 19 insertions, 0 deletions
diff --git a/tests/lang/eval-okay-with.nix b/tests/lang/eval-okay-with.nix
new file mode 100644
index 000000000000..033e8d3aba57
--- /dev/null
+++ b/tests/lang/eval-okay-with.nix
@@ -0,0 +1,19 @@
+let {
+
+  a = "xyzzy";
+
+  as = {
+    a = "foo";
+    b = "bar";
+  };
+
+  bs = {
+    a = "bar";
+  };
+
+  x = with as; a + b;
+
+  y = with as; with bs; a + b;
+
+  body = x + y;
+}