James Carlson wrote: > Roland Mainz writes: > > James Carlson wrote: > > [snip] > > > As for strMANYcat, the operation seems sort of obvious and somewhat > > > useful, but I wonder how often in real, well-written code this > > > situation actually comes up _and_ snprintf isn't a better answer. > > > > Umpf. See my original posting. My intention was to improve performance > > and usuability. |snprintf()| would make it slower. MUCH slower. > > I don't believe it makes any noticable difference for any plausible > usage model. > > In other words, prove it.
Erm...are you serious ? |sprintf()| involves parsing the format string and tons of other stuff while the proposed variant of |strcat()| (called |stpcpy()| in DICE-C and Linux) is just a plain string copy. The common sense and a quick benchmark shows that this is much faster than |sprintf()|&co. ... > > And: snprintf() may be evil - see Mozilla.org Bug 332006 > > (https://bugzilla.mozilla.org/show_bug.cgi?id=332006 - "Avoid raw calls > > to snprintf"). > > That bug report is either just a Linux library flaw or pure bunkum. Actually it seems to be a problem with the Microsoft compiler if I read the later comments in the bug report correctly... ;-( ---- Bye, Roland -- __ . . __ (o.\ \/ /.o) [EMAIL PROTECTED] \__\/\/__/ MPEG specialist, C&&JAVA&&Sun&&Unix programmer /O /==\ O\ TEL +49 641 7950090 (;O/ \/ \O;) _______________________________________________ opensolaris-discuss mailing list opensolaris-discuss@opensolaris.org