formatError assumes string sequence
Bug #587112 reported by
Cory Dodt
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
PyMeta |
New
|
Undecided
|
Unassigned |
Bug Description
Here's a simple test case. This prints an AttributeError for lines = input.split('\n') inside formatError.
#------
from pymeta.grammar import OMeta
g = """xyz ::= [ "xx":a "yy":b "zz":c ] => 'pass'"""
XYZ = OMeta.makeGramm
input = ['xx', 'OOPS', 'zz']
try:
print XYZ([input]
except Exception, e:
print e
print e.formatError(
To post a comment you must log in.