In article <[EMAIL PROTECTED]>, Amaury Forgeot d'Arc <[EMAIL PROTECTED]> wrote: >[EMAIL PROTECTED] a écrit : >> Hey, >> >> I'm writing a script to generate code. I'm a bit tired of typing >> outfile.write(....). Does python have a way to c-like macros? Every >> instance of o(...) in the code will be replaced by outfile.write(...)? > >First: Python has no macro facility. . . . For the sake of completeness, I want to note that the standard distribution includes Tools/Scripts/ifdef.py, and pyparsing now has an example macro preprocessor. Neither of these would be the correct response to the original question, of course, but they might interest other readers who believe they need "c-like macros".
-- http://mail.python.org/mailman/listinfo/python-list