I'd imagine you'd use it like so (in more modern C):
void *memcpy(void *src, void *dst, size_t len)
char *rv = dst;
while (len--) *dst++ =*src; /* not always a trivial body */
rv = dst; /* Swap args and jump to memcpy */
dst = src;
src = rv;
Variations on this theme are often done in assembler for these routines,
though the example is an attempt to cope with the diversity of interfaces
that grew up after v6 unix was released in the world, so it's not likely
this particular example inspired it...
On Tue, Oct 30, 2018 at 4:00 AM Angelo Papenhoff <aap(a)papnet.eu> wrote:
On 30/10/18, Steve Simon wrote:
“entry” was a reserved word in K&R Ed.1,
my personal favourite C trivia. I have never seen it used outside
I think PL/1 on Multics uses it, which is probably how it "got into" C.