Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!ub!uhura.cc.rochester.edu!troi.cc.rochester.edu!elmo From: elmo@troi.cc.rochester.edu (Eric Cabot) Newsgroups: comp.lang.pascal Subject: Re: Gotos are okay, but what about COME-FROM's?? Message-ID: <11866@ur-cc.UUCP> Date: 25 Jan 91 16:10:20 GMT References: <1991Jan24.112445.3829@kcbbs> <1991Jan25.175604.34@csc.canterbury.ac.nz> Sender: news@uhura.cc.rochester.edu Organization: University of Rochester, Rochester NY Lines: 42 While we are on the subject of Exit, I really miss the form of Exit used by UCSD pascal-whereby you could exit out of several nested procedures. Although I happily switched to Turbo years ago, the UCSD version is, IMHO, far more general and useful. Here's an example of how it worked: Program non_turbo_exit; procedure a; procedure b; procedure c; begin (*c*) exit(a); writeln(' very') (*never executed*) end; (*c*) begin (*b*) c; writeln('cold ') (*never executed*) end; (*b*) begin (*a*) b; writeln('cruel') (*never executed*) end; (*a*) begin (*main*) writeln('hello'); a; writeln('world') end. (*main*) Notice that the statement exit(a) takes the execution back to the point the a was called in main. -Just My $0.02 worth -- =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+= Eric Cabot | elmo@uhura.cc.rochester.edu "insert your face here" | elmo@uordbv.bitnet =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=