home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #1 / NN_1993_1.iso / spool / comp / lang / ada / 3863 < prev    next >
Encoding:
Text File  |  1993-01-04  |  2.7 KB  |  60 lines

  1. Newsgroups: comp.lang.ada
  2. Path: sparky!uunet!zaphod.mps.ohio-state.edu!cs.utexas.edu!milano!teenwolf.mcc.com!srogers
  3. From: srogers@teenwolf.mcc.com (Steve Rogers)
  4. Subject: Re: C++ vs. Ada -- Is Ada loosing?
  5. Message-ID: <1993Jan4.152223.18577@mcc.com>
  6. Sender: news@mcc.com
  7. Organization: MCC, Austin, Texas
  8. References: <EACHUS.92Dec18164915@oddjob.mitre.org> <1992Dec21.161105.9344@mcc.com> <MMEYER.92Dec31114831@m2.dseg.ti.com>
  9. Date: Mon, 4 Jan 1993 15:22:23 GMT
  10. Lines: 48
  11.  
  12. In article <MMEYER.92Dec31114831@m2.dseg.ti.com> mmeyer@m2.dseg.ti.com (Mark Meyer) writes:
  13. >
  14. >    I'm new to this group, basically because I'm new to Ada.
  15. >Even so, I just have to comment on this:
  16. >
  17. >In article <1992Dec21.161105.9344@mcc.com> srogers@teenwolf.mcc.com (Steve Rogers) writes:
  18. >> The edition I am looking at is the 3rd edition.
  19. >
  20. >    Are you sure?  I'm looking at the 3rd Edition myself.  When
  21. >was your copy printed?  This book seems to go through a reprint twice
  22. >every year, and mine's from 1990.  I only ask because both your
  23. >examples of errors seem to be in error themselves, at least as far as
  24. >my copy is concerned.
  25. >
  26. >> Two examples: The FRAME program on page 325 violates LRM 9.1.4 - the
  27. >> type of the task cannot be used as a typemark within the task itself.
  28. >> It's easy to see what the program means, but it doesn't comple. 
  29. >
  30. >    No, it doesn't violate 9.1.4.  I could tell that by
  31. >inspection.  I was even able to compile it (after removing references
  32. >to the FRAME package - I don't know how to get our compiler to build a
  33. >library and someone else has the manual).  Nowhere in the task body of
  34. >FILTER does anyone try to use FILTER as a type.  In fact, on p. 327
  35. >Barnes specifically states, "(The use of the function MAKE_FILTER is
  36. >necessary to overcome a rule that in the body of a task type its name
  37. >refers to the current task and not the type.)"
  38.  
  39. The date on my copy is 1989.  The FILTER task references itself on page 326.
  40. I suppose the error was found and corrected in later editions.
  41.  
  42. >> There is a task example on page 311 that has nested accepts for the
  43. >> same entry which violates LRM 9.5(8).  Again, its clear what the
  44. >> program intends, but it has been simplified in a way that keeps it
  45. >> from compiling.
  46. >
  47. >    I was able to compile this program too.  In my copy of the
  48. >book, the accepts are not nested.  Do you have the 3rd Edition,
  49. >printed in 1990?  Maybe your book was printed earlier?
  50.  
  51. Whoops!  I misread this one.  
  52.  
  53. The correction of the FRAME error answers the larger question of whether
  54. or not the errors were intentionally included to make the examples
  55. "easier" to understand.  It appears that this is NOT the case.
  56.  
  57. -- 
  58. | Steven Rogers  MCC/ESL  3500 West Balcones Drive
  59. | Austin, Texas 78759-6509  (512) 338-3691 srogers@mcc.com
  60.