Guido van Rossum wrote: > > > Enable a command line option [-p filename.py] and a related > > environment variable PYTHONPREPROCESS. The new behavior of the > > interpreter would then be to submit all of its input to the > > preprocess program (a module written in pure python) and then > > interpret the result. > > Instead of encumbering the standard Python interpreter, why not write > a script that runs its argument after preprocessing it, and inserts a > preprocessor in __import__. Or even more subtle: wait until PEP 263 phase 2 is implemented and write a codec which does the preprocessing for you on a per module basis, then you'd write: #!/usr/local/bin/python # coding: utf-8-with-macros macro yadada(a,b,c): print a,b,c -- Marc-Andre Lemburg CEO eGenix.com Software GmbH ______________________________________________________________________ Company & Consulting: http://www.egenix.com/ Python Software: http://www.egenix.com/files/python/
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4