home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #3 / NN_1993_3.iso / spool / comp / sys / mac / oop / macapp3 / 593 < prev    next >
Encoding:
Internet Message Format  |  1993-01-24  |  1.5 KB

  1. Path: sparky!uunet!olivea!apple!applelink.apple.com
  2. From: ALANDAIL@AppleLink.Apple.COM (Personal Software, Alan Dail,PRT)
  3. Newsgroups: comp.sys.mac.oop.macapp3
  4. Subject: C++ (was re: bedrock defection
  5. Message-ID: <727841301.8123714@AppleLink.Apple.COM>
  6. Date: 24 Jan 93 01:50:00 GMT
  7. Sender: daemon@Apple.COM
  8. Organization: AppleLink Gateway
  9. Lines: 23
  10.  
  11. Larry,
  12.  
  13. >...as safe as Pascal.... MPW C++ may not catch as many errors as it should,
  14. >but that's a compiler problem, not a language problem.
  15.  
  16. I would tend to disagree.  C and C++ both allow so many things to compile that
  17. could easily be typos but cause the program to do the wrong thing (I do admit
  18. that C++ is better than C).  For example, anywhere you can use a ==, you can
  19. also use = (and vice versa) and have the program compile fine (due to the
  20. definition of the language), but get different results.  Your program will not
  21. only compile, but may even work fine in some instances.  It doesn't even stand
  22. out when you are looking over your code.  This error would be cought in Pascal
  23. (or even in Pascal '9x), but not in C or C++.
  24.  
  25. There are other many other problems like this that are part of the language and
  26. not due to the compiler.  This doesn't even address the other language problems
  27. like having various features clash when used together or having the wrong
  28. defaults when using features (why isn't virtual the default?).  It's a shame
  29. that Apple doesn't appear to be doing anything with Pascal '9x which appears to
  30. give programmers the power of C++ without nearly as many pitfalls.
  31.  
  32. Alan
  33.  
  34.