home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / lang / fortran / 2880 < prev    next >
Encoding:
Text File  |  1992-07-30  |  1.9 KB  |  51 lines

  1. Newsgroups: comp.lang.fortran
  2. Path: sparky!uunet!zaphod.mps.ohio-state.edu!moe.ksu.ksu.edu!ux1.cso.uiuc.edu!news.cso.uiuc.edu!usenet
  3. From: r-larkin@uiuc.edu (Ron Larkin)
  4. Subject: Re: Why CALL EXIT? (was Re: Question for C ==> Fortran)
  5. References: <1992Jul28.075514.28683@debbie.cc.nctu.edu.tw> <1992Jul29.134901.1@slacvx.slac.stanford.edu> <1992Jul29.204115.3917@walter.cray.com>
  6. Message-ID: <Bs7I3H.Bu2@news.cso.uiuc.edu>
  7. Sender: usenet@news.cso.uiuc.edu (Net Noise owner)
  8. Organization: Illinois Natural History Survey
  9. Date: Thu, 30 Jul 1992 14:40:27 GMT
  10. Lines: 39
  11.  
  12. In article <1992Jul29.204115.3917@walter.cray.com> wws@craywr.cray.com (Walter
  13. Spector) writes:
  14. >
  15. >In article <1992Jul29.134901.1@slacvx.slac.stanford.edu>,
  16. fairfield@slacvx.slac.stanford.edu writes:
  17. >|> [a bunch of stuff, then...]
  18. >|>         CALL EXIT
  19. >|>         END
  20. >|>
  21. >|> The "CALL EXIT" at the bottom is optional (more-or-less). A "STOP"
  22. statement
  23. >|> would do just as well.
  24. >
  25. >This is something I have never understood in almost 20 years of Fortran
  26. >programming.  Why do so many people use the non-standard CALL EXIT
  27. >instead of the standardized-for-over-25-years STOP statement?
  28. >Is/was there magic associated with it on some arcane systems?
  29.  
  30.    One possible reason is that one may then later write one's own SUBROUTINE
  31. EXIT that does some clean-up work or that terminates the program in a certain
  32. way.  In this case, though, I would prefer to see the programmer CALL
  33. CLEAN_UP_AND_EXIT (or some other non-confusable name), that does whatever if
  34. any clean-up is required and then STOPs or CALLs EXIT.
  35.    If environment-specific code (even the rather generic CALL EXIT) is
  36. sequestered within a separate module, it's easier to change later (e.g. to
  37. STOP) or to port to another environment.
  38.  
  39. >Walt
  40. >-- 
  41. >Walt Spector
  42. >(wws@renaissance.cray.com)
  43. >Sunnyvale, California
  44. >_._ _._ _.... _. ._.
  45.  
  46. Ron
  47.  
  48. Ronald P. Larkin, Illinois Natural History Survey
  49. 607 E. Peabody Drive, Champaign, IL 61820  USA
  50. r-larkin@uiuc.edu (Ron Larkin)
  51.