| 233 | self._stop_to_block[(arena, stop)] = block |
| 234 | |
| 235 | def _absorb(self, block): |
| 236 | # deregister this block so it can be merged with a neighbour |
| 237 | (arena, start, stop) = block |
| 238 | del self._start_to_block[(arena, start)] |
| 239 | del self._stop_to_block[(arena, stop)] |
| 240 | |
| 241 | length = stop - start |
| 242 | seq = self._len_to_seq[length] |
| 243 | seq.remove(block) |
| 244 | if not seq: |
| 245 | del self._len_to_seq[length] |
| 246 | self._lengths.remove(length) |
| 247 | |
| 248 | return start, stop |
| 249 | |
| 250 | def _remove_allocated_block(self, block): |
| 251 | arena, start, stop = block |