|
10 | 10 | This is the pure Python implementation of the module.
|
11 | 11 | """
|
12 | 12 |
|
13 |
| -__all__ = ['abs', 'add', 'and_', 'attrgetter', 'call', 'concat', |
14 |
| - 'in_', 'not_in', 'contains', 'countOf', |
| 13 | +__all__ = ['abs', 'add', 'and_', 'attrgetter', 'call', 'concat', 'contains', 'countOf', |
15 | 14 | 'delitem', 'eq', 'floordiv', 'ge', 'getitem', 'gt', 'iadd', 'iand',
|
16 |
| - 'iconcat', 'ifloordiv', 'ilshift', 'imatmul', 'imod', 'imul', |
| 15 | + 'iconcat', 'ifloordiv', 'ilshift', 'imatmul', 'imod', 'imul', 'in_', |
17 | 16 | 'index', 'indexOf', 'inv', 'invert', 'ior', 'ipow', 'irshift',
|
18 | 17 | 'is_', 'is_not', 'isub', 'itemgetter', 'itruediv', 'ixor', 'le',
|
19 | 18 | 'length_hint', 'lshift', 'lt', 'matmul', 'methodcaller', 'mod',
|
20 |
| - 'mul', 'ne', 'neg', 'not_', 'or_', 'pos', 'pow', 'rshift', |
| 19 | + 'mul', 'ne', 'neg', 'not_', 'not_in', 'or_', 'pos', 'pow', 'rshift', |
21 | 20 | 'setitem', 'sub', 'truediv', 'truth', 'xor']
|
22 | 21 |
|
23 | 22 | from builtins import abs as _abs
|
@@ -151,22 +150,18 @@ def concat(a, b):
|
151 | 150 | raise TypeError(msg)
|
152 | 151 | return a + b
|
153 | 152 |
|
154 |
| - |
155 | 153 | def in_(a, b):
|
156 | 154 | "Same as a in b."
|
157 | 155 | return a in b
|
158 | 156 |
|
159 |
| - |
160 | 157 | def not_in(a, b):
|
161 | 158 | "Same as a not in b."
|
162 | 159 | return a not in b
|
163 | 160 |
|
164 |
| - |
165 | 161 | def contains(a, b):
|
166 | 162 | "Same as b in a (note reversed operands)."
|
167 | 163 | return b in a
|
168 | 164 |
|
169 |
| - |
170 | 165 | def countOf(a, b):
|
171 | 166 | "Return the number of items in a which are, or which equal, b."
|
172 | 167 | count = 0
|
|
0 commit comments