Author: Lukas Diekmann <[email protected]>
Branch: set-strategies
Changeset: r49183:0a8c1ba28319
Date: 2011-05-27 14:41 +0200
http://bitbucket.org/pypy/pypy/changeset/0a8c1ba28319/

Log:    not needed anymore

diff --git a/pypy/objspace/std/setobject.py b/pypy/objspace/std/setobject.py
--- a/pypy/objspace/std/setobject.py
+++ b/pypy/objspace/std/setobject.py
@@ -13,28 +13,6 @@
 from pypy.interpreter.generator import GeneratorIterator
 from pypy.objspace.std.listobject import W_ListObject
 
-def get_strategy_from_w_iterable(space, w_iterable=None):
-    assert False
-    from pypy.objspace.std.intobject import W_IntObject
-    #XXX what types for w_iterable are possible
-
-    if isinstance(w_iterable, W_BaseSetObject):
-        return w_iterable.strategy
-
-    if w_iterable is None:
-        #XXX becomes EmptySetStrategy later
-        return space.fromcache(ObjectSetStrategy)
-
-    if not isinstance(w_iterable, list):
-        w_iterable = space.listview(w_iterable)
-    for item_w in w_iterable:
-        if type(item_w) is not W_IntObject:
-            break;
-        if item_w is w_iterable[-1]:
-            return space.fromcache(IntegerSetStrategy)
-
-    return space.fromcache(ObjectSetStrategy)
-
 class W_BaseSetObject(W_Object):
     typedef = None
 
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to