home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #30 / NN_1992_30.iso / spool / comp / lang / cplus / 17814 < prev    next >
Encoding:
Text File  |  1992-12-11  |  1.5 KB  |  33 lines

  1. Newsgroups: comp.lang.c++
  2. Path: sparky!uunet!pipex!warwick!bham!bhamvx!mccauleyba
  3. From: mccauleyba@vax1.bham.ac.uk (Brian McCauley)
  4. Subject: Re: char* to const char*&
  5. Sender: usenet@rs6000.bham.ac.uk (USENET News Service)
  6. Message-ID: <1992Dec11.175805.1@vax1.bham.ac.uk>
  7. Date: Fri, 11 Dec 1992 17:58:05 GMT
  8. Lines: 21
  9. References: <JPOLITO.92Dec11092330@sysgem1.encore.com>
  10. Organization: University of Birmingham
  11.  
  12. In article <JPOLITO.92Dec11092330@sysgem1.encore.com>, jpolito@sysgem1.encore.com (Jonathan Polito) writes:
  13. > I am curious to what the current wisdom is on accepting char* as a
  14. > valid argument to a function expecting const char*& e.g.
  15.  
  16. The net wisdom as distilled from a long discussion a few weeks back is that
  17. one can not allow a `char**' argument to a function wanting a `const char **'.
  18.  
  19. There as a feeling that perhaps the language should allow a `char *' argument
  20. for a `const char * const *' argument.
  21.  
  22. The reference situation is no different so the language should not (and to
  23. the best of my knowlwdge does not) allow a `char*' value for a `const char*&'
  24. argument but should (and I think does) allow one for a `const char * const &'
  25. argument.
  26. -- 
  27.     \\   ( )    No Bullshit!     |  Email: B.A.McCauley@bham.ac.uk   
  28.  .  _\\__[oo        from         |  Voice: +44 21 471 3789 (home)
  29. .__/  \\ /\@    /~)  /~[   /\/[  |    Fax: +44 21 625 2175 (work)
  30. .  l___\\      /~~) /~~[  /   [  |  Snail: 197 Harborne Lane,
  31.  # ll  l\\    ~~~~ ~   ~ ~    ~  |         Birmingham, B29 6SS, UK
  32. ###LL  LL\\   (Brian McCauley)   |   ICBM: 52.5N 1.9W
  33.