A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2002-March/021382.html below:

[Python-Dev] A Hygienic Macro System in Python?

[Python-Dev] A Hygienic Macro System in Python? [Python-Dev] A Hygienic Macro System in Python?Skip Montanaro skip@pobox.com
Mon, 18 Mar 2002 15:45:40 -0600
    Tom>   define macro unless
    Tom>     { unless (?test:expression) ?:body end }
    Tom>      => { if (~ ?test) ?body end }

    ...

    Tom> I find using 'unless' makes some things more readable. To learn the
    Tom> internals of the compiler I've been adding an unless statement to
    Tom> Python, but one shouldn't need to do this in order to add useful
    Tom> constructions like this.

Try this on for size:

    http://groups.google.com/groups?hl=en&ie=ISO-8859-1&oe=ISO-8859-1&frame=right&th=e4809653296a3b71&seekm=mailman.1016132066.3225.python-list%40python.org#link1

It may allow you to do some things like unless without messing around with
the compiler proper, though it is clearly nothing more than a neat little
hack.

Skip




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