code: def fix_e702(self, result, logical):
          
          if not logical:
              return []  # pragma: no cover
          logical_lines = logical[2]
  
          # Avoid applying this when indented.
          # https://docs.python.org/reference/compound_stmts.html
          for line in logical_lines:
              if (result['id'] == 'E702' and ':' in line
                      and STARTSWITH_DEF_REGEX.match(line)):
                  return []
  
          line_index = result['line'] - 1
          target = self.source[line_index]
  
          if target.rstrip().endswith('\\'):
              # Normalize '1; \\\n2' into '1; 2'.
              self.source[line_index] = target.rstrip('\n \r\t\\')
              self.source[line_index + 1] = self.source[line_index + 1].lstrip()
              return [line_index + 1, line_index + 2]
  
          if target.rstrip().endswith(';'):
              self.source[line_index] = target.rstrip('\n \r\t;') + '\n'
              return [line_index + 1]
  
          offset = result['column'] - 1
          first = target[:offset].rstrip(';').rstrip()
          second = (_get_indentation(logical_lines[0]) +
                    target[offset:].lstrip(';').lstrip())
  
          # Find inline comment.
          inline_comment = None
          if target[offset:].lstrip(';').lstrip()[:2] == '# ':
              inline_comment = target[offset:].lstrip(';')
  
          if inline_comment:
              self.source[line_index] = first + inline_comment
          else:
              self.source[line_index] = first + '\n' + second
          return [line_index + 1]
docs: Put semicolon-separated compound statement on separate lines.