Will python never intend to support private, protected and public?

Mike Meyer mwm at mired.org
Mon Oct 3 05:02:54 EDT 2005


Paul Rubin <http://phr.cx@NOSPAM.invalid> writes:
> Mike Meyer <mwm at mired.org> writes:
>> > Privilege separation is considered a good coding practice.  How does
>> > Python help it?
>> With conventions and name mangling. Which are only slightly less
>> effective than the C++/Java technic for doing the same thing.
> That's not what privilege separation means.  It means that the
> privileged objects stay secure even when the unprivileged part of the
> program is completely controlled by an attacker.

In which case, what's "private" got to do with this? The examples I've
seen of it don't give you privilege seperation any more than python
does.

Of course, while we're adding things to Python to support what people
consider good coding practices, let's not forget:

         Design by contract.
         Covariant method specialization.
         Class invariants.
         Avoiding variable aliasing.
         Hungarian Notation.
         The Law of Demeter.
         Loop invariants.
         Avoiding mixed mode arithmetic.
         The telephone test.
         Procedure/function sepration.
         Type discipline.
         Contravariant method specialization.    

and so on.

         <mike

-- 
Mike Meyer <mwm at mired.org>			http://www.mired.org/home/mwm/
Independent WWW/Perforce/FreeBSD/Unix consultant, email for more information.



More information about the Python-list mailing list