(self, obj)
| 1007 | return |
| 1008 | |
| 1009 | def save_set(self, obj): |
| 1010 | save = self.save |
| 1011 | write = self.write |
| 1012 | |
| 1013 | if self.proto < 4: |
| 1014 | self.save_reduce(set, (list(obj),), obj=obj) |
| 1015 | return |
| 1016 | |
| 1017 | write(EMPTY_SET) |
| 1018 | self.memoize(obj) |
| 1019 | |
| 1020 | it = iter(obj) |
| 1021 | while True: |
| 1022 | batch = list(islice(it, self._BATCHSIZE)) |
| 1023 | n = len(batch) |
| 1024 | if n > 0: |
| 1025 | write(MARK) |
| 1026 | for item in batch: |
| 1027 | save(item) |
| 1028 | write(ADDITEMS) |
| 1029 | if n < self._BATCHSIZE: |
| 1030 | return |
| 1031 | dispatch[set] = save_set |
| 1032 | |
| 1033 | def save_frozenset(self, obj): |
nothing calls this directly
no test coverage detected