Boost logo

Boost Users :

From: Yuval Ronen (ronen_yuval_at_[hidden])
Date: 2005-02-01 01:50:25


>>I haven't tried it, but I have a feeling that it will work for string
>>literals, but not for c-string variables
>
>
> With "c-string variables", do you mean pointer to char? Or something like
> MFC's CString?

pointer to char

> Anyway, the first is supported as before. The above just ensures that the
> type passed to the rest of lexical_cast is the same type it used to be, when
> it used pass by value. So arrays will decay to pointers, and everything else
> will pass through unaltered. I ran the above through the unit test, and it
> passes all, on the three compilers I tested it with. I've since talked with
> Kevlin, and this was also what he had in mind, to make pass by const
> reference work.

Ok. As I said, this comment was made without trying it, so it's quite
possible (and even probable) that I was mistaking. I'll be more careful
next time (spank on the tush for me...)


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net