[Python-Dev] Capabilities (we already got one)

Ka-Ping Yee ping@zesty.ca
Tue, 1 Apr 2003 14:12:49 -0600 (CST)

On Tue, 1 Apr 2003, Zooko wrote:
> I think that in restricted-execution-mode (hereafter: "REM", as per Greg Ewing's
> suggestion [1]), Python objects have encapsulation -- one can't access their
> private data without their permission.
> Once this is done, Python references are capabilities.

Aaack!  I wish you would *stop* saying that!

There is no criterion by which a reference is or is not a capability.
To talk in such terms only confuses the issue.

It is possible to program in a capability style in any Turing-complete
programming language, just as it is possible to program in an object
style or a functional style or a procedural style.  The question is:
what does programming in a capability style look like, and how might
Python facilitate (or even encourage) that style?

To say that activating restricted execution mode causes things to
"become" capabilities is as meaningless as saying that adding a feature
to the C language would suddenly turn an arbitrary C program into an
object-oriented program.

-- ?!ng