Re: cString operator= with same buffer

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Clemens Kirchgatterer wrote:

>Holger Brunn <holger.brunn@xxxxxxxxxxxxxxxxxxxxx> wrote:
>
>  
>
>>>I think something should be done to fix the "assign cString to
>>>itself" case, even though this is very unlikely. This does go wrong
>>>with the current code, even with the copy constructor added.
>>>      
>>>
>>Okay, now as all seems to be said, here is a patch that checks for
>>that case (that may happen when working with references/pointers to
>>cStrings), leaving Klaus with the decision whether it's useful to
>>have it or not.
>>    
>>
>
>why not just:
>
>typedef std::string cString;
>
>or:
>
>class cString : public std::string { ... };
>
>i really can't understand all this messing with a datatype allready
>implemented elsewhere. what is so special about cString that other
>string implementations do not have?
>  
>
AFAIR it is because of Klaus disliking standard stuff  like stl, 
utf-8,gettext , ntpl and so on.

regards,
gunnar



[Index of Archives]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Util Linux NG]     [Xfree86]     [Big List of Linux Books]     [Fedora Users]     [Fedora Women]     [ALSA Devel]     [Linux USB]

  Powered by Linux