Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 02 Nov 1999 03:40:22 +0300
From:      Dmitrij Tejblum <tejblum@arc.hq.cti.ru>
To:        Warner Losh <imp@village.org>
Cc:        freebsd-arch@freebsd.org
Subject:   Re: stpcpy() 
Message-ID:  <199911020040.DAA03010@tejblum.pp.ru>
In-Reply-To: Your message of "Sun, 31 Oct 1999 23:05:45 MST." <199911010605.XAA04972@harmony.village.org> 

next in thread | previous in thread | raw e-mail | index | archive | help
Warner Losh wrote:
> For example, the following program is strictly standards conforming,
> but would break if we added this change:

[example snipped].

s/stpcpy/index/g, and you will get a strictly standard conforming 
program that already broken on FreeBSD. A random programmer 
will much more likely name his function `index' than `stpcpy'.

Anyhow, if a program is actually standard conforming, it should be 
compiled with -D_ANSI_SOURCE or -D_POSIX_SOURCE (depending on the 
standard it conform to), and still work fine. That is, you are 
_wrong_, no conforming program would break.

Some non-conforming programs may break, but it is their fault :-).

> Just because it is in every compiler you have ever used doesn't make
> it desirable to have it our libc.  

Just because it is useful (and being used) make it desirable to have it
in our libc. (Then, after another 20 or so years, stpcpy() will be in the
standard. :-) This is the purpose of the C language - be convenient.)

Dima






To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-arch" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199911020040.DAA03010>