home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / sys / amiga / programmer / 3806 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.9 KB

  1. Path: sourcery.han.de!not-for-mail
  2. Newsgroups: comp.sys.amiga.programmer
  3. References: <13213602@sourcery.han.de> <1005.6624T1300T707@teclink.net> <Dn668q.5Kr@cyf-kr.edu.pl>
  4. From: "Olaf Barthel" <olsen@sourcery.han.de>
  5. Date: Sat, 24 Feb 1996 15:41:55 +0100
  6. X-NewsReader: IntuiNews 1.3a (7.9.95)
  7. Subject: Re: Update to Native Developer Kit 3.1: Request for ideas
  8. Message-ID: <13213658@sourcery.han.de>
  9.  
  10. In Article <Dn668q.5Kr@cyf-kr.edu.pl>, Kamil Iskra <iskra@student.uci.agh.edu.pl> wrote:
  11. > rad (rad@teclink.net) wrote:
  12. > > The thing I would like most to see in an update is the correcting of
  13. > > prototypes in headers to indicate when constant pointers can be passed.
  14. >
  15. > > (e.g. in clib/dos.h:
  16. >
  17. > > BPTR Open (CONST STRPTR name, long accesMode);
  18. > > LONG Write (BPTR file, CONST APTR buffer, long length);
  19. > > LONG DeleteFile (CONST STRPTR name);
  20. > > LONG Rename (CONST STRPTR oldName, CONST STRPTR newName);
  21. > > BPTR Lock (CONST STRPTR name, long type);
  22. >
  23. > Good point! It would make programming easier and would let compilers make
  24. > more optimizations in some cases.
  25.  
  26.    Yep, if the compiler plays by the rules.
  27.  
  28. > Another thing in this subject that needs updating is converting all UBYTE*
  29. > (and maybe char*, too) to STRPTR - they cause huge amount of warnings when
  30. > compiling in C++, which uses stricter pointer checking and will not ignore
  31. > "char*" <-> "unsigned char*" mismatches.
  32.  
  33.    Noted.
  34.  
  35. > Another thing is including all necessary headers before declaring
  36. > prototypes in "clib" files. As "necessary" I mean headers that contain
  37. > structures which are used in prototypes. ANSI C says that scope of
  38. > structures implicitly declared in prototypes ends with the end of...
  39. > prototype! This effectively makes this prototypes useless. Many compilers,
  40. > including SAS/C, work well with such code, but GNU CC does not and is
  41. > *right* - this is violation of ANSI standard.
  42.  
  43.    Noted.
  44.  
  45. --
  46. Home: Olaf Barthel, Brabeckstrasse 35, D-30559 Hannover
  47.  Net: olsen@sourcery.han.de
  48.