Returns the index of the last occurrence of the content argument in the stack, or returns None if content is not on the stack.
(self, content)
| 68 | self._writes.append(s) |
| 69 | |
| 70 | def find_last_write(self, content): |
| 71 | """ |
| 72 | Returns the index of the last occurrence of the content argument |
| 73 | in the stack, or returns None if content is not on the stack. |
| 74 | """ |
| 75 | try: |
| 76 | return len(self._writes) - self._writes[::-1].index(content) - 1 |
| 77 | except ValueError: |
| 78 | return None |
| 79 | |
| 80 | def insert_write(self, index, content): |
| 81 | """ |
no outgoing calls