From: timv Date: Wed, 12 Dec 2012 21:46:50 +0000 (-0500) Subject: working on some javascript hacks to help us manage our compiler output. X-Git-Url: https://hydra-www.ietfng.org/gitweb/?a=commitdiff_plain;h=517aa278ec8b8be54f513df556dae404f910c12b;p=dyna2 working on some javascript hacks to help us manage our compiler output. --- diff --git a/bin/prototype.py b/bin/prototype.py index 2f26a42..cde9e52 100644 --- a/bin/prototype.py +++ b/bin/prototype.py @@ -205,12 +205,42 @@ def main(dynafile): print >> html, '' + print >> html, """\ + + + +""" + print >> html, '

%s

' % dynafile print >> html, '

Dyna source

' - print >> html, '
\n%s\n
' % code.strip() + + print >> html, '
' + + print >> html, '
'
+        with file(dynafile) as f:
+            for lineno, line in enumerate(f, start=1):
+                print >> html, '%s' % (lineno, line.rstrip())
+        print >> html, '
' + + print >> html, '
' + + print >> html, '
' + + print >> html, '
' + + + print >> html, '
' anf = toANF(code)