Hi ENoch,

> Here is my current solution to eliminating defer indirection in simple
> forward reference cases:
> 
> variable back&forth
> \ use forward referenced word 
> : forth&  dp back&forth ! -1 ,  ;  immediate
> \ use forward referenced xt 
> : &forth  postpone (literal) -1 , dp 1- back&forth !  ;  immediate
> \ forward reference resolver (put anywhere in referenced word)
> : &back&  latest @ back&forth @ !i  ;  immediate
> 
> \ 1st calling 2nd examples:
> \
> \ : first1  ." first1 " forth& ;
> \ : second1  ." second1" &back&  ;
> \
> \ : first2  ." first2 " &forth execute  ;
> \ : second2  ." second2" &back&  ;
> 
> Comments or is this "cookbook grade" :-)

What is the expected output? 

The wording of your new commands didn't help (me)
either. I tried to refactor it to

 variable fxt
 : >fxt dp fxt ! -1 , ; immediate
 : <fxt latest @ fxt @ !i ; immediate

But it is a hidden thing, what the &forth should do.
I had the impression, that a forward declaration could
be used multiple times, so it should be resolved not
only once. I do not see anything even nearby in your 
code.

Sorry, you lost me

Matthias

------------------------------------------------------------------------------
CenturyLink Cloud: The Leader in Enterprise Cloud Services.
Learn Why More Businesses Are Choosing CenturyLink Cloud For
Critical Workloads, Development Environments & Everything In Between.
Get a Quote or Start a Free Trial Today.
http://pubads.g.doubleclick.net/gampad/clk?id=119420431&iu=/4140/ostg.clktrk
_______________________________________________
Amforth-devel mailing list for http://amforth.sf.net/
Amforth-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/amforth-devel

Reply via email to