home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #3 / NN_1993_3.iso / spool / comp / std / cplus / 2137 < prev    next >
Encoding:
Text File  |  1993-01-28  |  875 b   |  28 lines

  1. Newsgroups: comp.std.c++
  2. Path: sparky!uunet!taumet!steve
  3. From: steve@taumet.com (Steve Clamage)
  4. Subject: Re: sprintf return value
  5. Message-ID: <1993Jan28.190759.28006@taumet.com>
  6. Organization: TauMetric Corporation
  7. References: <1993Jan26.202158.21195@digi.lonestar.org>
  8. Date: Thu, 28 Jan 1993 19:07:59 GMT
  9. Lines: 17
  10.  
  11. mharriso@digi.lonestar.org (Mark Harrison) writes:
  12.  
  13. >Will the C++ standard specify the return type of sprintf()?
  14.  
  15. Yes.  The C++ Standard will incorporate the library portion of the
  16. ANSI/ISO C standard (with some minor modifications):
  17.  
  18.     int sprintf(char* buf, const char* fmt, ...);
  19.  
  20. It returns the number of characters stored in buf, like the rest of
  21. the printf family.
  22.  
  23. Some C libraries have sprintf return buf (a char*), for reasons I
  24. have never understood.  This is neither standard C nor standard C++.
  25. -- 
  26.  
  27. Steve Clamage, TauMetric Corp, steve@taumet.com
  28.