[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: CVS update: subversion/subversion/client add-cmd.c checkout-cmd.c cl.h commit-cmd.c delete-cmd.c main.c propget-cmd.c proplist-cmd.c props.c propset-cmd.c status-cmd.c update-cmd.c

From: Branko Èibej <brane_at_xbc.nu>
Date: 2000-11-19 21:28:07 CET

Greg Stein wrote:

> How would you declare strchr() do return the same type as what was passed
> in, *and* restrict it to once of "const char *" or "char *" ??

Overload.

    char* strchr (char*);
    const char* strchr (const char*);

It works. In fact, that's standrd C++ strchr, IIRC.

>> (But in general, C++ does NOT look real good, IMO.)
>
>
> I vehemently agree :-)

Ah, language wars, huh? That coming from people who code in C, of all
things. :-)

-- 
Brane �ibej
    home:   <brane_at_xbc.nu>             http://www.xbc.nu/brane/
    work:   <branko.cibej_at_hermes.si>   http://www.hermes-softlab.com/
     ACM:   <brane_at_acm.org>            http://www.acm.org/
Received on Sat Oct 21 14:36:15 2006

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.