(no subject)
Brian Rice
water at tunes.org
Fri Feb 24 17:51:56 PST 2006
Hello all,
I've added a feature via request that puts REPL actions implicitly
into a separate "scratch" namespace that is separate from the lobby
(or whatever namespace the REPL evaluates in). This required a small
addition to namespace.slate which was bootstrapped in, so new images
are needed to use it.
Here's a bottom-up summary of the changes:
- newDelegatingTo: was added to Namespace to make a fresh one with a
delegation slot to the target.
- newSubSpace makes a new fresh Namespace that delegates to the
argument.
- The REPL now creates a fresh "subspace" of the lobby (or whatever
namespace it should use) when entered, and implicit-sends are
evaluated in that. The usual REPL-installed methods mentioned by the
help text are installed on this "subspace".
- "repl refreshWorkspace" re-initializes this setup. "repl reset"
does not call this, it just clears the history.
- The REPL actually has a REPL Workspace type derived from Namespace
for possible future behavioral enhancement.
- "in: namespace" can be called to re-target the scratch namespace's
delegation to the target object. For now, this does not work terribly
well, and I'm going to explore what it takes to get a suitable
substitute for the lobby and why. Basically for now it only works for
subspaces of the lobby.
None of this is cast in stone; that is, if you have better ideas or
suggestions for more natural or uniform idioms, they would be
welcome. And of course this does nothing for true sandboxing or
security protection - it just means that "addSlot: #x" and
"define: ..." calls don't accumulate scratch work in the lobby.
Enjoy!
--
-Brian
http://tunes.org/~water/brice.vcf
-------------- next part --------------
A non-text attachment was scrubbed...
Name: PGP.sig
Type: application/pgp-signature
Size: 186 bytes
Desc: This is a digitally signed message part
Url : /archives/slate/attachments/20060224/d42c10dc/PGP.pgp
More information about the Slate
mailing list