re.compile(
    """\\bfunction\\b \\s*[a-zA-Z0-9._]*
\\(
(
  (?:
    (?:[a-zA-Z_][a-zA-Z0-9_]*|\\.\\.\\.)
    (?: ,\\s* (?:[a-zA-Z_][a-zA-Z0-9_]*|\\.\\.\\.) )*
  )?
)
\\)"""
    , re.VERBOSE)
Case of poor Python 're' performance