traceWhatIs works for empty lists

svn path=/nixpkgs/trunk/; revision=12046
This commit is contained in:
Michael Raskin 2008-06-12 06:58:07 +00:00
parent 9dd45a58cf
commit e8e0d1665c
1 changed files with 1 additions and 0 deletions

View File

@ -341,6 +341,7 @@ rec {
if (x ? outPath) then "x is a derivation with name ${x.name}"
else "x is an attr set with attributes ${builtins.toString (__attrNames x)}"
else if (__isFunction x) then "x is a function"
else if (x == []) then "x is an empty list"
else if (__isList x) then "x is a list, first item is : ${whatis (__head x)}"
else if (x == true || x == false) then builtins.toString x
else "x is probably a string starting, starting characters: ${__substring 0 50 x}..";