Vendor supplied names, was Re: string comparisons in C

David Adrien Tanguay datanguay at watmath.waterloo.edu
Sat Jul 15 18:34:55 AEST 1989


In article <12689 at bloom-beacon.MIT.EDU> scs at adam.pika.mit.edu (Steve Summit) writes:
>
>No vendor should provide a routine named "pnmatch."  Vendors are
>not supposed to pollute the namespace with "convenient" (but
>invariably unportable and system-specific) routines.  ("Then why
>do so may vendors do so?" you ask.)  Vendor-supplied routines not
>mentioned in the standard are supposed to have names beginning
>with at least one underscore (e.g. "_pnmatch").

I don't think this is correct (however, the standard is at work, I'm not).
It is okay for the vendor to provide a function with a name in the user
name space, so long as the standard routines do not access it (by that name),
and so long as any user supplied same name gets linked in first.
For example, it would be nice for the vendor to supply a read() (etc.).

David Tanguay



More information about the Comp.lang.c mailing list