macro FAQ

John J. Lee jjl at
Sun Aug 24 20:47:30 CEST 2003

Jacek Generowicz <jacek.generowicz at> writes:

> jjl at (John J. Lee) writes:
> I agree. However, my feeling was that the original contained too much
> uneducated opinion. I was trying to suggest that we first establish
> the facts, and then include opinions based on those facts, rather than
> ones based on FUD. Particularly, we should banish the myth that macros
> fragment languages, or make code less unedrstandable. (Quite the
> reverse is true.)

It would be nice to make a definitive ruling :-), but it seems clear
most people here disagree with that.  If Andrew's FAQ answer is going
to be linked to, no reason why other people can't supply an
alternative answer and have that linked to from the Python FAQ too.

> I agree that abstractions usually hide details. I disagree with the
> claim that hiding details is the essence of abstraction. To me, the
> essence of abstraction is noticing a similarity between certain
> "things", understandig how they differ, and encoding the whole set of
> them in one implementation, with an obvious degree of freedom which
> selects a specific "thing" from the whole family.

Or, abstracting a bit: hiding details <wink>.

> If I have a function which is 400 lines long, and I choose to make it
> clearer by cutting and pasting bits of its body into smaller
> functions, and calling those functions from the original, I haven't
> abstracted anything; I have merely split it into more digestible
> chunks.

We're probably in violent agreement.


More information about the Python-list mailing list