Home | History | Annotate | Download | only in python2.7

Lines Matching refs:other

147     then the other operations will automatically follow suit.
150 def __le__(self, other):
151 if not isinstance(other, Set):
153 if len(self) > len(other):
156 if elem not in other:
160 def __lt__(self, other):
161 if not isinstance(other, Set):
163 return len(self) < len(other) and self.__le__(other)
165 def __gt__(self, other):
166 if not isinstance(other, Set):
168 return other < self
170 def __ge__(self, other):
171 if not isinstance(other, Set):
173 return other <= self
175 def __eq__(self, other):
176 if not isinstance(other, Set):
178 return len(self) == len(other) and self.__le__(other)
180 def __ne__(self, other):
181 return not (self == other)
192 def __and__(self, other):
193 if not isinstance(other, Iterable):
195 return self._from_iterable(value for value in other if value in self)
197 def isdisjoint(self, other):
199 for value in other:
204 def __or__(self, other):
205 if not isinstance(other, Iterable):
207 chain = (e for s in (self, other) for e in s)
210 def __sub__(self, other):
211 if not isinstance(other, Set):
212 if not isinstance(other, Iterable):
214 other = self._from_iterable(other)
216 if value not in other)
218 def __xor__(self, other):
219 if not isinstance(other, Set):
220 if not isinstance(other, Iterable):
222 other = self._from_iterable(other)
223 return (self - other) | (other - self)
272 then the other operations will automatically follow suit.
404 def __eq__(self, other):
405 if not isinstance(other, Mapping):
407 return dict(self.items()) == dict(other.items())
409 def __ne__(self, other):
410 return not (self == other)
538 other = args[1] if len(args) >= 2 else ()
540 if isinstance(other, Mapping):
541 for key in other:
542 self[key] = other[key]
543 elif hasattr(other, "keys"):
544 for key in other.keys():
545 self[key] = other[key]
547 for key, value in other: