Subject: EXITFOR

From: Kent Pitman <[email-masked]>
Date: Wed, 12 May 1993 10:56:47 -0700

Hmm.  So much mail.  Well, I agree multiple level exits are good,
and I don't like break.  The following would do me:

 block <block_name>
   ... return_from <block_name>;
 endblock

That way I could do

 block search
   found = 0;
   for item in (search_path)
     if (item.lost)
       found=item;
       return_from search;
     endif
   endfor
 endblock

and even if it was a doubly-nested loop, I'd still win.
Similarly, for the "skip" concept that someone mentioned,...

 for x in (y)
   block skip
     if (x.skipme) return_from skip;
     ... more stuff ...
   endblock
 endfor

(In generaly, I actually like the simpler name "exit" better than
 "return_from", but I bet "exit" is a popular variable name in MOO, 
 so it's probably bad and I tried to pick another name that wasn't
 likely to upset things.  I don't know if the same problem exists
 for "block", but I presume Pavel can `easily' (at LagdaMOO's expense)
 check with @grep.)

---

From: Pavel Curtis <[email-masked]>
Date: Wed, 12 May 1993 11:14:23 -0700

> Date:	Wed, 12 May 1993 10:56:47 -0700
> From:	Kent Pitman <[email-masked]>
> 
> (In general, I actually like the simpler name "exit" better than

No particular need, really.  Version 1.8.0 of the server already has a facility
for loading an old database into a new server that has some new keywords; it
checks for conflictingly-named variables and renames them during parsing.  This
was necessary in order to add the new exception-handling stuff.  I agree,
though, that `exit' might not be a very good choice of keyword for MOO...

	Pavel