Path: utzoo!mnetor!uunet!husc6!uwvax!rutgers!mtunx!whuts!homxb!hropus!ki4pv!tanner From: tanner@ki4pv.uucp (Dr. T. Andrews) Newsgroups: comp.lang.c Subject: Re: noalias, again (was extern const) Message-ID: <6986@ki4pv.uucp> Date: 25 Mar 88 01:11:23 GMT References: <7712@apple.Apple.Com> <7485@brl-smoke.ARPA> <10731@mimsy.UUCP> Organization: Kitchen Sink Dep't Lines: 19 Summary: Another "existing practice" meets X3J11, with predictable results. In article <10731@mimsy.UUCP>, chris@mimsy.UUCP (Chris Torek) writes: [ cites "strcpy" definition in latest draft, includes \fInoalias\fP, gives clear example of code now broken by X3J11: f() { char buf[SIZE]; int n; /* ... */ /* remove leading junk (n < strlen(buf)) */ (void)strncpy(buf, buf+n); ] It should be noted that at one time, the idea of this standardization effort was to codify existing practice. Breaking existing, useful code is hard to justify under the banner of existing practice. Must we now come up with some sort of quasi-standard replacement for "strcpy" and friends, free of this "noalias" (and also perhaps "const", depending on the final wording of "const") boondoggle, if we are to write useful code that deals with strings? DMR, where are you when we need you? -- {allegra clyde!codas decvax!ucf-cs ihnp4!codas killer}!ki4pv!tanner