home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #19 / NN_1992_19.iso / spool / comp / lang / cplus / 13054 < prev    next >
Encoding:
Internet Message Format  |  1992-08-29  |  3.6 KB

  1. Path: sparky!uunet!sun-barr!ames!pacbell.com!UB.com!igor!thor!rmartin
  2. From: rmartin@thor.Rational.COM (Bob Martin)
  3. Newsgroups: comp.lang.c++
  4. Subject: Re: GOTO, was: Tiny proposal for na
  5. Message-ID: <rmartin.715104177@thor>
  6. Date: 29 Aug 92 16:02:57 GMT
  7. References: <1992Aug26.130335.26725@hemlock.cray.com> <1992Aug26.194538.1598@spss.com> <rmartin.714931485@thor> <2330@devnull.mpd.tandem.com>
  8. Sender: news@Rational.COM
  9. Lines: 69
  10.  
  11. rgp@mpd.tandem.com (Ramon Pantin) writes:
  12.  
  13. |Anyhow, you can't really do nothing about it, 
  14.  
  15.  
  16. I agree! Something has to be done.  I'm just trying to do my part.
  17.  
  18. |nobody is going to outlaw
  19. |any of these, nobody is going to stop using them either, even if you
  20. |don't like them (we like them), so learn to live with them.
  21.  
  22. I do live with them, despite the discomfort.  I'm not sitting in some
  23. ivory tower somewhere, contemplating my navel and how there aren't any
  24. gotos in it.  I write code.  Lots of it.  And I read more than I
  25. write.  And the code I read is often laced with breaks, continues, and
  26. even gotos.  I don't barf all over this code, nor do I refuse to read
  27. it.  Dealing with it is part of my job.  I just wish all the engineers
  28. who write that code would make that part of my job easier by being a
  29. bit more careful.
  30.  
  31. |>In software engineering, we have rules, but no cops.  (And I don't
  32. |>want any cops either).  So "real good programmers" sometimes feel that
  33. |>the rules don't apply to them.  We average types suffer at their hands.
  34.  
  35. |The problem is that when you say "we have rules" you mean "I have rules",
  36. |you have your rules and I have my rules.  I don't feel guilty when I
  37. |use breaks, continues, returns, gotos or when I decide that a state
  38. |variable makes more sense than any of these.  If you don't like using
  39. |some of these, that is ok also, go ahead and don't use them, don't be
  40. |afraid, I won't send my cops to look at your code.
  41.  
  42. f=ma is a rule.  It is not 100% accurate, but it is pretty damned
  43. close.  You can say "Its not my rule" if you like, but that doesn't
  44. make it any less valid.
  45.  
  46. Structured programming has proven its benefits over the last 15 years.
  47. It may not have as much experimental support as f=ma, but it does have
  48. a lot.  If you don't want it to be one of your rules, that's your
  49. choice, but that doesn't make it any less valid.  
  50.  
  51. |Textbook software engineering for computer science students is not
  52. |exactly how things work in the real world.  
  53.  
  54. How well I know!  So few of the engineers have read the damned
  55. textbook.  However, I think the industry would greatly benefit if the
  56. textbook were taken more seriously by more engineers.
  57.  
  58. |If somebody in the real world
  59. |is making you "suffer at their hands" with good old C code, you can always
  60. |find yourself a project that is being done strictly under your rules.
  61. |If you can't find one, then you might be more tolerant of all the
  62. |programmers that have not seen the light and give them some space.
  63. |Please don't suffer too much if one of them puts a "break" in one of
  64. |your statefull loops.
  65.  
  66. Now who's not in the real world.  My interests do not lie in finding
  67. some nice structured niche to hide in.  To quote you: "you cant do
  68. nothing about it."  I don't indend to do nothing.  I intend to teach
  69. and expound and discuss these issues, over and over again.  Structured
  70. programming works.  More importantly, the benefits to be derived from
  71. OOP will be eroded if SP is forgotten.
  72.  
  73.  
  74.  
  75. --
  76. Robert Martin                        Training courses offered in:
  77. R. C. M. Consulting                       Object Oriented Analysis
  78. 2080 Cranbrook Rd.                        Object Oriented Design
  79. Green Oaks, Il 60048 (708) 918-1004       C++
  80.