String copy idiom.

Henry Spencer henry at utzoo.UUCP
Sat Mar 9 04:55:33 AEST 1985


> In the mean time, if your application does a great deal of
> string copying, and you are want to minimize execution time,
> you should write your own string copy routine.

If you do so, please put a comment on your private routine to
explain why it's there, so the people maintaining it fifteen years
from now don't tear their hair out trying to discover why you re-
implemented a standard library routine.  Also, please put a note about
it in the documentation for the application.  Your routine may well
be slower on the next machine it gets ported to.
-- 
				Henry Spencer @ U of Toronto Zoology
				{allegra,ihnp4,linus,decvax}!utzoo!henry



More information about the Comp.lang.c mailing list