code: def get_escape(self, c, i):
          
  
          try:
              escaped = next(i)
          except StopIteration:
              escaped = ''
          return c + escaped if self.keep_escapes else escaped
docs: Get an escape.