Boost logo

Boost :

From: Loïc Joly (loic.actarus.joly_at_[hidden])
Date: 2008-03-04 08:05:03


Phil Endecott a écrit :
I've been using it for quite some time now, so here are my remarks :

> - It uses size_type to pass and return positions in the string, and
> doesn't specify whether these are byte or character positions; I get
> the impression that they're character positions but I could be wrong.
>
>
It is character positions.
> - It offers implicit conversion to and from std::string. Is this desirable?
>
In my experience, it is very bad. It is not a conversion, but a
reinterpretation.

Even a str() function would seem bad, unless it has a parameter that
states in which encoding the resulting string is desired. A conversion
from/to std::wstring would seem more useful in most cases.

-- 
Loïc

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk