home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.lang.forth      Forth programmers eat a lot of Bratwurst      117,927 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 117,012 of 117,927   
   Hans Bezemer to dxf   
   Re: "Back & Forth" - Local variables   
   09 Jan 25 17:15:24   
   
   From: the.beez.speaks@gmail.com   
      
   On 09-01-2025 13:42, dxf wrote:   
   >> There is no guarantee that a saved interpreter pointer on the   
   >> stack is an execution token.   
      
   Nope - in ANS-Forth it is listed as:   
      
   nest-sys; definition calls; implementation dependent   
      
   So - that's obvious. But in 4tH it works out. And defining it as >R   
   works out as well. BTW, I've tested the thing - and it holds up.   
      
   I got my work cut out for a next episode! On co-routines! ;-)   
      
   Hans Bezemer   
      
   BTW, I've heard there are implementations where nest-sys aren't even on   
   the return stack. The standard seems to confirm this:   
      
   return stack:  A stack that _MAY_BE_ used for program execution nesting,   
   do-loop execution, temporary storage, and other purposes.   
      
   .. and sorry to spoil the fun, but what we're doing here is illegal anyways:   
      
   "A program shall _NOT_ access values on the return stack (using R@, R>,   
   2R@ or 2R>) that it _DID_NOT_ place there using >R or 2>R;"   
      
   In other words: your mileage may (be) very, very illegal.   
      
   Hans Bezemer   
      
   --- SoupGate-DOS v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca