diff options
Diffstat (limited to 'BibTeX.py')
| -rw-r--r-- | BibTeX.py | 11 |
1 files changed, 6 insertions, 5 deletions
@@ -6,12 +6,10 @@ Based on perl code by Eddie Kohler; heavily modified. """ -import cStringIO import re import sys import config - from entry import BibTeXEntry __all__ = ['ParseError', 'BibTeX', 'FileIter', 'Parser', 'parseFile'] @@ -67,7 +65,8 @@ class BibTeX: del ent['crossref'] if cr.entryLine < ent.entryLine: - print "Warning: crossref %s used after declaration" % cr.key + print ("Warning: crossref %s used after " + "declaration" % cr.key) for k in cr: if k in ent: @@ -246,7 +245,8 @@ class Parser: data.append(m.group(1)) line = m.group(2) else: - raise ParseError("Questionable line at line %s" % self.lineno) + raise ParseError("Questionable line " + "at line %s" % self.lineno) # Got a string, check for concatenation. if line.isspace() or not line: @@ -268,7 +268,8 @@ class Parser: m = BRACE_BEGIN_RE.match(line) if not m: - raise ParseError("Expected an opening brace at line %s" % self.lineno) + raise ParseError("Expected an opening " + "brace at line %s" % self.lineno) line = m.group(1) proto = {'string': 'p', 'preamble': 'v'}.get(self.curEntType, 'kp*') |
