home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / std / c / 2486 < prev    next >
Encoding:
Text File  |  1992-08-20  |  2.4 KB  |  63 lines

  1. Newsgroups: comp.std.c
  2. Path: sparky!uunet!hoptoad!kithrup!sef
  3. From: sef@kithrup.COM (Sean Eric Fagan)
  4. Subject: Re: ANSI/ISO standard (surprisingly enough!) & extensions
  5. Organization: Kithrup Enterprises, Ltd.
  6. Date: Thu, 20 Aug 1992 20:50:31 GMT
  7. Message-ID: <1992Aug20.205031.10606@kithrup.COM>
  8. References: <1992Aug19.234812.11723@unix.brighton.ac.uk>
  9. Lines: 52
  10.  
  11. In article <1992Aug19.234812.11723@unix.brighton.ac.uk> amn@vms.brighton.ac.uk writes:
  12. >1   It is only applicable to compilers that include a complete ANSI library,
  13. >    often not the case when targetting embedded systems, ...
  14.  
  15. Not true:  there are several parts to the PH suite, one which tests the
  16. compiler, and one which tests the compiler-plus-libraries (as well as
  17. possible other parts; it's been a long time since I've seen the suite).
  18.  
  19. >2   It does not check that system constants (#define's) and function prototypes
  20. >    are in the correct header files, ...
  21.  
  22. Uhm, yes, it does.  It can do things like:
  23.  
  24.     char *cp;
  25.  
  26.     main() { if (cp == NULL) return 0; else return 1; }
  27.  
  28. That will fail.  It can also include a header file, and reference all of the
  29. constants, types, and functions that are supposed to be in that header file.
  30. Remember:  the PH suite checks for things that *should* fail, as well as
  31. things that should pass!
  32.  
  33. >3   It does not ensure that the compiler defaults to ANSI compliant mode, with
  34. >    language extensions being available only as an option.
  35.  
  36. That is an implementation detail, and I can guarantee that there are *few*
  37. compilers which will *default* to ANSI:  it's too limited.  One of the
  38. things you configure the PH suite to do is to invoke the compiler the way
  39. you want it to be;
  40.  
  41. >4   It does not prevent tampering with the input (PH) files to get the desired
  42. >    output.
  43.  
  44. Nothing will.  Get real.  However, if you claim ANSI conformance, based on
  45. passing the PH test suite, and a customer gets your compiler, and runs it
  46. thruogh the suite, and it fails, don't you think someone is going to make a
  47. bit of noise about that?
  48.  
  49. >5   It does not reject compilers that accept invalid operations or illegal
  50. >    syntax.
  51.  
  52. Yes, it does.
  53.  
  54. >6   It does not test typesafe linkage, where implemented :-)
  55.  
  56. Not required by ANSI.
  57.  
  58. -- 
  59. Sean Eric Fagan  | "You can't get lost in in one room, no matter how
  60. sef@kithrup.COM  |  little effort you make to learn your way around."
  61. -----------------+    -- William E Davidsen (william@crd.GE.COM)
  62. Any opinions expressed are my own, and generally unpopular with others.
  63.