[EMAIL PROTECTED] wrote: > The C standards folks aren't that stupid. The function should not > have their return values const qualified because in the majority > of cases: > - the argument isn't const > - the return value is going to be modified. > > The const qualifier for the argument is merely stating that the > function itself will not modify the argument. > > It does, unfortunately, give a typing hole as you can convert const char * > to char * using strchr() and others.
The question would be if the C standard commitee could define something like this: typeof(arg1) strchr(const char *, char) or something similar that would carry the actual input over to the return value. Jörg -- EMail:[EMAIL PROTECTED] (home) Jörg Schilling D-13353 Berlin [EMAIL PROTECTED] (uni) [EMAIL PROTECTED] (work) Blog: http://schily.blogspot.com/ URL: http://cdrecord.berlios.de/old/private/ ftp://ftp.berlios.de/pub/schily _______________________________________________ opensolaris-discuss mailing list opensolaris-discuss@opensolaris.org