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,951 messages   

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

   Message 117,271 of 117,951   
   dxf to Hans Bezemer   
   Re: Why dial-a-standard is not a thing i   
   02 May 25 19:04:21   
   
   From: dxforth@gmail.com   
      
   On 2/05/2025 6:55 am, Hans Bezemer wrote:   
   > On 01-05-2025 03:23, dxf wrote:   
   >> On 30/04/2025 11:58 pm, Hans Bezemer wrote:   
   >>> On 30-04-2025 04:37, dxf wrote:   
   >>>> On 30/04/2025 2:50 am, Hans Bezemer wrote:   
   >>>>> ...   
   >>>>> To force myself to add messages to THROWs (especially in libs with   
   special conditions) I added THROW" - it works like a combination of ABORT" and   
   THROW. You need to specify a THROW code, you need to specify a flag and you   
   need to specify a message.   
   >>>>   
   >>>> What happens in the case of CATCH - what's left on the stack?   
   >>>>   
   >>> Surprise, surprise - THROW" calls THROW (actually, it inlines the whole   
   shebang). So - what do you think?   
   >>   
   >> For ABORT" the string is suppressed and only the code (-2) is left.   
   >> Is that what THROW" does with the string?   
   >>   
   >> AFAIK on most forth systems exceptions generate either an error code or an   
   >> error message (the latter via ABORT" or caught code).  In short, what good   
   >> is having both a msg and a code?   
   >>   
   >   
   > In 4tH, ABORT is really abort. It does what the label says. It can't be   
   caught. If you want to abort, I assume you want to abort. If you wanna catch   
   it, use THROW. C'mon. I designed it as a man's language ;-)   
      
   Well you did say 'THROW" calls THROW' and since the code # is unlikely to be   
   that of ABORT what is a self-respecting forther going to assume? :)   
      
   I had a look at DX-Forth to see what it would take to print both string and   
   code number.  While it can be done I'm not sure the extra code is warranted.   
   The other factor is I never implemented ANS codes -3 onwards.  If apps use   
   THROW at all they're generally caught.  Otherwise everything is ABORT or   
   ABORT" .  I do have ?ABORT ( n adr len -- ) which works the same way as the   
   FI's.  I don't think I've used it as yet.   
      
   --- 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