Yes --- that is a good example.
I am actually well aware that Factor quotations do have access to the parent 
function's local variables --- I remember this from my brief foray into Factor 
about 5 or 6 years ago --- I just wanted to confirm it because, as I said, the 
Forth-200x committee is faking up :NONAME as a quotation and saying that Factor 
also has similar fake quotations (no access to the parent function's local 
variables).
To a large extent, my FMITE was designed for the purpose of proving that at 
least one Forth programmer in the world knows what quotations are --- I would 
like to see it implemented in an FPGA, but even if it doesn't come to fruition, 
I will have still made my point that true quotations are possible.
regards --- Hugh

     On Sunday, July 5, 2015 8:32 PM, John Benediktsson <mrj...@gmail.com> 
wrote:
   
 

 I'm not sure what you mean, but I assume something like this:
    :: foo ( seq -- seq' )
        1 :> temp
        seq [ temp + ] map ;
    IN: scratchpad { 1 3 5 } foo .    { 2 4 6 }
Yes, that works.
If thats not what you meant, can you clarify?
On Fri, Jul 3, 2015 at 3:58 PM, Hugh Aguilar <hughaguila...@yahoo.com> wrote:

Is it true that in Factor the quotation has access to the parent function's 
local variables?
Over on comp.lang.forth Bernd Payson has said that in Factor quotations do not 
have access to the parent function's local variables --- he uses this argument 
to justify that his "quotations" (just :NONAME with some syntactic sugar) don't 
need to have access to the parent function's locals.
Anyway, in LOTD my quotations have access to the parent function's local 
variables.
regards --- Hugh


 
  
------------------------------------------------------------------------------
Don't Limit Your Business. Reach for the Cloud.
GigeNET's Cloud Solutions provide you with the tools and support that
you need to offload your IT needs and focus on growing your business.
Configured For All Businesses. Start Your Cloud Today.
https://www.gigenetcloud.com/
_______________________________________________
Factor-talk mailing list
Factor-talk@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/factor-talk

Reply via email to