No Thoughts about Everything
noemail at noemail4u.com
Thu Feb 26 19:09:04 CET 2004
On Wed, 25 Feb 2004 10:57:30 -0700, "Dave Brueck"
<dave at pythonapocrypha.com> wrote:
>> >class Foo:
>> > BAR = 10
>> >Voila! BAR is now a "class constant" - shared among all instances of the
>> >Foo (in theory it's not a constant, but in practice it is :) ).
>> But not 'final'.
>> I am only anticipating a response.
>> IMO - if I am understanidng the issues correctly - it is a perfectly
>> adequate solution. Simple to get across to beginners..
>> The issue of making the constant 'final' is a production programming
>> issue. And whether Python does or does not need it is not an issue
>> relative to teaching beginners. The fact that production programming
>> concerns are introduced at that stage of the game is, I think, where
>> many who would otherwise have an intellectual intererst in programming
>> fall of the wagon. Wanting to understand programming and wanting to
>> be a production programmer can be very different things.
>True, but IMO this particular issue is invalid as a "production programming
>concern" as well - it doesn't prevent any problems that actually occur in
>practice, or if it does, you have bigger problems on your hands. It falls into
>the same bucket of concerns as "our programmers are untrained monkeys and/or
>are seeking to destroy our company from the inside".
+1 on this. If the code has gotten to production, and someone is
changing (or trying to and silently failing) a final/constant value,
something seems a little non-production about it. What's the Wiki
More information about the Python-list