<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def pop_frame(self):
 """ Pops the current contextual frame off of the stack and returns the cursor to the frame's return position. """

        try:
            offset, return_pos = self._frames.pop()
        except IndexError:
            raise IndexError('no frames to pop')
        self._total_offset -= offset

        self.seek(return_pos)