Python becoming less Lisp-like

news.sydney.pipenetworks.com nytimes at swiftdsl.com.au
Wed Mar 16 22:04:17 EST 2005


Jeff Shannon wrote:
> news.sydney.pipenetworks.com wrote:
> 
>> More in relation to the original topic, why can't people just ignore 
>> features they don't understand and may never use directly. 
> 
> 
> Because they may get stuck maintaining code that uses those features. 
>  Now, I'm generally in agreement with you -- in general, Python features 
> that aren't straightforward (e.g. metaclasses) are clearly advanced 
> features and aren't likely to be in everyday code.  I'm okay with just 
> knowing that metaclasses exist, and having a vague idea of how one would 
> use them.
> 
> But the more features that some people ignore, the more that they tend 
> to write in a customized dialect that's a subset of the full language. 
>  And the more people write code in their own personal (or group) 
> dialect, the more fragmented the worldwide codebase becomes, and the 
> harder it is to understand code that doesn't come from the circle of 
> developers who you're directly familiar with.

I don't totally understand what you're getting at here, but here's my 
take. If people can implement something which can be done using 
metaclasses without using metaclasses then I don't see a problem with 
this. However if someone implements something using metaclasses which 
can be done via other simpler means, then this is a just a education 
problem. It's like the procedural vs functional vs oo programming 
argument all over again. Some people will use OO for everything when it 
may not be best. etc. etc.

> It's true that a given programmer doesn't need to understand every 
> feature of the language, but it's not really fair to say "ignore it and 
> it won't affect you" -- there's still a cost associated with such 
> features that can't be ignored away.  In some cases that cost is well 
> worth bearing (as is the case for metaclasses and descriptors, 
> especially as these two examples are implementation artifacts that would 
> exist whether they were exposed to programmers or not), but in other 
> cases it won't be, so it's important to keep in mind that the cost exists.

Of course theres a cost with every feature. But with time that costs 
approaches zero if it becomes as rampant as is being suggested because 
you will get use to it. If you see it once every blue moon, well then 
you'll just have to have one very bad day at work.

Huy



More information about the Python-list mailing list