Boost logo

Boost :

From: Vladimir Prus (ghost_at_[hidden])
Date: 2004-02-14 14:21:06


Hi Pavol,

> On Sat, Feb 14, 2004 at 07:29:00PM +0300, Vladimir Prus wrote:
> > > It could be templatized so that it can be based on any kind of
> > > std::basic_string.
> >
> > Alas, that would break ability to put all sources in a library -- thereby
> > increasing compile time for users who don't need wchar_t support.
>
> AFAIR, there were several solutions for this problem.
>
> I don't see many other reasonable options besides char and wchar_t.
> So why don't just allow these specializations. Then you can put them into
> cpp files.
>
> std::string in STL is handled in very similar way.

There's other very attactive option. If most of the time when user wants
wchar_t he also need to specify 8bit encoding -> unicode convertion,
it's possible to *always* use wchar_t and convert it to char only on interface
boundaries.

That's similiar to QT approach -- where there's single string class.

- Volodya


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