Code cleanup and applied pyflakes' suggestions.

parent 3e04c23b
......@@ -2,9 +2,7 @@
"""
A simple pybison parser program implementing a calculator
"""
import sys
from bison import BisonParser, BisonNode
from bison import BisonParser
class Parser(BisonParser):
"""
......
......@@ -2,9 +2,7 @@
"""
A simple pybison parser program implementing a calculator
"""
import sys
from bison import BisonParser, BisonNode
from bison import BisonParser
class Parser(BisonParser):
"""
......
#!/usr/bin/env python
import readline
import sys
sys.path.insert(0, '../../build/lib.linux-x86_64-2.7/')
......
......@@ -3,9 +3,10 @@
A more advanced calculator example, with variable storage and scientific
functions (courtesy of python 'math' module)
"""
import sys, math, readline
import math
from bison import BisonParser
from bison import BisonParser, BisonNode, BisonError
class Parser(BisonParser):
"""
......
......@@ -25,7 +25,7 @@ else:
src = "I2PClient.java"
p = myjava.Parser(verbose=verbose)
p = javaparser.Parser(verbose=verbose)
print "delmebld.py: running parser on HelloWorldApp.java"
res = p.run(file=src)
......
......@@ -11,7 +11,7 @@ You can do much worse than to copy this file
somewhere, and tinker away to your heart's content.
"""
import sys, traceback
import sys
from bison import BisonParser, BisonNode
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment