about summary refs log tree commit diff
path: root/tvix/eval/src
diff options
context:
space:
mode:
Diffstat (limited to 'tvix/eval/src')
-rw-r--r--tvix/eval/src/tests/nix_tests/eval-okay-fromjson.exp (renamed from tvix/eval/src/tests/nix_tests/notyetpassing/eval-okay-fromjson.exp)0
-rw-r--r--tvix/eval/src/tests/nix_tests/eval-okay-fromjson.nix (renamed from tvix/eval/src/tests/nix_tests/notyetpassing/eval-okay-fromjson.nix)0
-rw-r--r--tvix/eval/src/tests/tvix_tests/eval-okay-eq-nested-list.exp1
-rw-r--r--tvix/eval/src/tests/tvix_tests/eval-okay-eq-nested-list.nix1
-rw-r--r--tvix/eval/src/value/mod.rs6
5 files changed, 5 insertions, 3 deletions
diff --git a/tvix/eval/src/tests/nix_tests/notyetpassing/eval-okay-fromjson.exp b/tvix/eval/src/tests/nix_tests/eval-okay-fromjson.exp
index 27ba77ddaf61..27ba77ddaf61 100644
--- a/tvix/eval/src/tests/nix_tests/notyetpassing/eval-okay-fromjson.exp
+++ b/tvix/eval/src/tests/nix_tests/eval-okay-fromjson.exp
diff --git a/tvix/eval/src/tests/nix_tests/notyetpassing/eval-okay-fromjson.nix b/tvix/eval/src/tests/nix_tests/eval-okay-fromjson.nix
index e1c0f86cc4e4..e1c0f86cc4e4 100644
--- a/tvix/eval/src/tests/nix_tests/notyetpassing/eval-okay-fromjson.nix
+++ b/tvix/eval/src/tests/nix_tests/eval-okay-fromjson.nix
diff --git a/tvix/eval/src/tests/tvix_tests/eval-okay-eq-nested-list.exp b/tvix/eval/src/tests/tvix_tests/eval-okay-eq-nested-list.exp
new file mode 100644
index 000000000000..27ba77ddaf61
--- /dev/null
+++ b/tvix/eval/src/tests/tvix_tests/eval-okay-eq-nested-list.exp
@@ -0,0 +1 @@
+true
diff --git a/tvix/eval/src/tests/tvix_tests/eval-okay-eq-nested-list.nix b/tvix/eval/src/tests/tvix_tests/eval-okay-eq-nested-list.nix
new file mode 100644
index 000000000000..5dbcb515295b
--- /dev/null
+++ b/tvix/eval/src/tests/tvix_tests/eval-okay-eq-nested-list.nix
@@ -0,0 +1 @@
+[["f" ""]] == [["f" ""]]
diff --git a/tvix/eval/src/value/mod.rs b/tvix/eval/src/value/mod.rs
index c590495b5344..ff9dccb0b3c2 100644
--- a/tvix/eval/src/value/mod.rs
+++ b/tvix/eval/src/value/mod.rs
@@ -332,15 +332,15 @@ impl Value {
                 lhs.force(vm)?;
                 rhs.force(vm)?;
 
-                Ok(*lhs.value() == *rhs.value())
+                lhs.value().nix_eq(&*rhs.value(), vm)
             }
             (Value::Thunk(lhs), rhs) => {
                 lhs.force(vm)?;
-                Ok(&*lhs.value() == rhs)
+                lhs.value().nix_eq(rhs, vm)
             }
             (lhs, Value::Thunk(rhs)) => {
                 rhs.force(vm)?;
-                Ok(lhs == &*rhs.value())
+                lhs.nix_eq(&*rhs.value(), vm)
             }
 
             // Everything else is either incomparable (e.g. internal