> 
> 
> There is no notion of current context.
> The same function can be referenced by words
> in two different objects, can't it?
> Therefore, which context is "current"?

yeah you're right, I'd forgotten that once bind is done, the function itself does not 
have any knowledge of context... each word stores its context by itself...

funny I forgot, since I gave a demo on this list of how you can have a block with the 
same three words in it with each one containing differrent information... its amazing 
how one has to bang his head until you figure just how powerfull this really is.

probe reduce [w w w] in rebol, can be made to print:

"something" "something else" "yet another value"

something which isn't possible in most other languages without inserting the reduced 
value in the block.

> It's probably infeasible to add a complete
> undo function, but perhaps an /original
> refinement

in theory, I already have the original function.

a /context refinement might be good to, where you replace the default /system/words/  
"context" by any path! value of your choosing. 

but, since the encompass returns the new function... the old one is not overidden 
until/unless YOU decide.  IT does not overide the function it merely uses it.  That is 
why in the example I backup read to old-read.  So if I ever wanted to reset read back 
by default, I'd just need to do:

read: :old-read

so maybe this whole restore/revert thing really isn't usefull, for all the problems it 
would create (and asumptions it would need).

like I said in one of my recent mails...

  Often, simple is longest to achieve.

we can go round and round and eventually, realize that all the nice ideas aren't as 
simple as if they didn't even exist.   ;-)


-MAx

> 
> Anton.
> 
> > > Max:
> > > 
> > > > Anyone... What is the best way for a function to detect if 
> > > it is part of an 
> > > > object?
> > > 
> > > One way would be to check if 'self is defined.
> > 
> > 
> > I though of that, but it is very possible that someone will use 
> > self in the global context. even checking if its type is object! 
> > isn't completely safe...
> > 
> > isn't there a way to probe the current context, one which works 
> > whether we are in an object or the global namespace ?
> > 
> > I might add a /bind refinement which forces a bind of the created 
> > function block to an object.  When used, It would implicitly make 
> > /revert function differently than when defined 'globally'.
> > 
> > 
> > As I don't need this functionality right now, I'll put it on the 
> > back burner, but if any one DOES need it, I'll raise the priority.
> > 
> > I'm pushing slim as the only code I write on right now... so 
> > everything else is secondary.
> > 
> > I want to start working on STEEL|FORGE SOOOOOO badly.
> > 
> > I might start working on a Q&D forge prototype (a closed 
> > rebol-coding exclusive toolset with no api) to bootstrap the real 
> > application and improve liquid-vid coding speed.
> > 
> > 
> > cheers!
> > 
> > -MAx
> 
> -- 
> To unsubscribe from this list, just send an email to
> [EMAIL PROTECTED] with unsubscribe as the subject.
> 
> 

-- 
To unsubscribe from this list, just send an email to
[EMAIL PROTECTED] with unsubscribe as the subject.

Reply via email to