'Emit a C-compiler-like, Emacs-friendly error-message leader.'

def error_leader(self, infile=None, lineno=None):

    if (infile is None):
        infile = self.infile
    if (lineno is None):
        lineno = self.lineno
    return ('"%s",    line    %d:    ' % (infile, lineno))
