Add a description of values which cause a bad type the failure.

svn path=/nixpkgs/trunk/; revision=16054
This commit is contained in:
Nicolas Pierron
2009-06-26 12:42:00 +00:00
parent c69010d6eb
commit dd50af4923
2 changed files with 10 additions and 8 deletions
+2
View File
@@ -43,6 +43,8 @@ rec {
traceCall2 = n : f : a : b : let t = n2 : x : traceShowValMarked "${n} ${n2}:" x; in t "result" (f (t "arg 1" a) (t "arg 2" b));
traceCall3 = n : f : a : b : c : let t = n2 : x : traceShowValMarked "${n} ${n2}:" x; in t "result" (f (t "arg 1" a) (t "arg 2" b) (t "arg 3" c));
traceValIfNot = c: x:
if c x then true else trace (showVal x) false;
/* Evaluate a set of tests. A test is an attribute set {expr,
expected}, denoting an expression and its expected result. The