Xref: utzoo alt.sources:1639 comp.lang.misc:4618 Path: utzoo!attcan!uunet!samsung!brutus.cs.uiuc.edu!ux1.cso.uiuc.edu!aries!mcdonald From: mcdonald@aries.scs.uiuc.edu (Doug McDonald) Newsgroups: alt.sources,comp.lang.misc Subject: Re: Big Mistake in System V TCL distribution. Message-ID: <1990Mar23.164630.24318@ux1.cso.uiuc.edu> Date: 23 Mar 90 16:46:30 GMT References: <18169@rpp386.cactus.org> Sender: usenet@ux1.cso.uiuc.edu (News) Reply-To: mcdonald@aries.scs.uiuc.edu (Doug McDonald) Organization: School of Chemical Sciences, Univ. of Illinois at Urbana-Champaign Lines: 21 In article <18169@rpp386.cactus.org> jfh@rpp386.cactus.org (John F. Haugh II) writes: >In article peter@ficc.uu.net (Peter da Silva) writes: >>In converting the program to System V, I inadvertently changed the >>string ``index'' to ``strchr'' in one place too many. Index is a tcl >>function. In tclBasic.c, in the table of function names, replace the >>occurrence of ``"strchr"'' with ``"index"''. > >This is probably one of those things that falls under the heading >of "really big mistakes." The number of systems which have "index" >as a library function is non-small. Given that the most common >trick used to port USG stuff to BSD land is "-Dstrchr=index", you >are going to have [ and anyone else who intentionally pulls this >stunt ] one hell of a large body of people pissed off at you. >-- "index" as a function name in a C standard library is not allowed. IF the C library in question has such a function, it is broken. "index" is a perfectly valid function to be defined in a user program. The "implemention defined" function names have a specific list of first characters. "i" isn't included. Tell your vendor to fix their library.