Boost logo

Boost :

Subject: Re: [boost] Boost review of the Convert library is ongoing
From: Rob Stewart (robertstewart_at_[hidden])
Date: 2014-05-16 05:35:31


On May 15, 2014 11:28:59 PM EDT, Edward Diener <eldiener_at_[hidden]> wrote:
>On 5/15/2014 9:42 PM, Vladimir Batov wrote:
>> alex <alexhighviz <at> hotmail.com> writes:
>>
>>> I found it confusing that the function "from" is used for
>conversion; I
>>> would expect there to be an equivalent "to" that does the reverse of
>>> "from", but there is not.
>>
>> I personally did not see the need for convert::to. So I do not have
>it. What
>> would be a use-case where you might need convert::to and convert
>::from
>> would not do?
>>
>>> I would therefore prefer "get", "do","parse" or "convert".
>>
>> Well, to me "convert<int>::from<string>" seems like a good
>"translation"
>> from English "convert int to string" to C++.
>
>I think you just misspoke here Vladimir, and meant "convert to int from
>string".

I noticed that and was going to say that he was arguing for "to" rather than "for".

The alternatives do not read well and having the result type on the left, plus the input type near the argument justifies the use of "from".

[snip entire remainder of Vladimir's message, including the ML footer]

Please don't over-quote.

___
Rob

(Sent from my portable computation engine)


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