about summary refs log tree commit diff
path: root/src/libexpr/eval.cc
diff options
context:
space:
mode:
authorEelco Dolstra <e.dolstra@tudelft.nl>2010-04-12T09·50+0000
committerEelco Dolstra <e.dolstra@tudelft.nl>2010-04-12T09·50+0000
commitdb90b88e655a0d8e501beddee966a124b2f097d8 (patch)
treef0997a9e85f424d95392fd0f2551801ac92d855d /src/libexpr/eval.cc
parent4e490025767093e287a8b7b01de52fee7ae36830 (diff)
* Hack to support builderDefs expressions.
Diffstat (limited to 'src/libexpr/eval.cc')
-rw-r--r--src/libexpr/eval.cc8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/libexpr/eval.cc b/src/libexpr/eval.cc
index 02f5e3dc8d53..7434aa842242 100644
--- a/src/libexpr/eval.cc
+++ b/src/libexpr/eval.cc
@@ -918,8 +918,14 @@ bool EvalState::eqValues(Value & v1, Value & v2)
     forceValue(v1);
     forceValue(v2);
 
+    /* !!! Hack to support some old broken code that relies on pointer
+       equality tests between attribute sets.  (Specifically,
+       builderDefs calls uniqList on a list of attribute sets.)  Will
+       remove this eventually. */
+    if (&v1 == &v2) return true;
+
     if (v1.type != v2.type) return false;
-    
+
     switch (v1.type) {
 
         case tInt: