import re


def _strip_sql(sql: str) -> str:
  """Returns a copy of sql with empty lines and -- comments stripped.

  Args:
    sql: A SQL string.
  Returns:
    A copy of sql with empty lines and -- comments removed.
  """
  lines = []
  for line in sql.split('\n'):
    line = re.sub(r'\s*--.*', '', line)
    if line.strip():
      lines.append(line)
  return '\n'.join(lines)