Author: Armin Rigo <ar...@tunes.org>
Branch: 
Changeset: r55079:9a59028a6d96
Date: 2012-05-14 11:27 +0200
http://bitbucket.org/pypy/pypy/changeset/9a59028a6d96/

Log:    Improve(?) the fix by saying that the temporarily nonsensical
        str.join([list-of-nones]) is also returning "".

diff --git a/pypy/annotation/unaryop.py b/pypy/annotation/unaryop.py
--- a/pypy/annotation/unaryop.py
+++ b/pypy/annotation/unaryop.py
@@ -493,11 +493,11 @@
             return SomeImpossibleValue()
         getbookkeeper().count("str_join", str)
         s_item = s_list.listdef.read_item()
-        if isinstance(s_item, SomeImpossibleValue):
+        if s_None.contains(s_item):
             if isinstance(str, SomeUnicodeString):
                 return immutablevalue(u"")
             return immutablevalue("")
-        no_nul = str.no_nul and getattr(s_item, 'no_nul', True)
+        no_nul = str.no_nul and s_item.no_nul
         return str.basestringclass(no_nul=no_nul)
 
     def iter(str):
_______________________________________________
pypy-commit mailing list
pypy-commit@python.org
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to