Subject: Re: [boost] conversion, cast.hpp (Was: [modularization] Recommendations)
From: Antony Polukhin (antoshkka_at_[hidden])
Date: 2014-06-08 10:32:26
2014-06-08 18:15 GMT+04:00 Peter Dimov <lists_at_[hidden]>:
> Stephen Kelly wrote:
>> Peter Dimov wrote:
>> > cast.hpp probably also needs to die, the polymorphic casts going into >
>> their own header. This will be post-release because it will break code, >
>> Actually it doesn't need to be a breaking change.
>> You can create a new polymorphic_cast.hpp in core and #include that in
>> cast.hpp, and move that cast.hpp (which now only contains two includes) to
>> numeric. Then you can deprecate cast.hpp with a pragma warning and port any
>> uses of it to include polymorphic_cast.hpp instead. Non breaking change.
> Yes, you are right. Moving cast.hpp to numeric/conversion is a better way
> to deal with it. There'll be no need to remove the numeric/ include then,
> and it will truly be a non-breaking change.
This does not look right. polymorpic_cast and polymotphic_downcast do not
look like they belong to Numeric. They do not deal with numbers at all.
> Re moving *_cast.hpp to Core, I actually prefer the other way, moving
> lexical_cast to its own module. Conversion will then drop to level 2, same
> as Core.
Most part of the Conversion dependencies are related to the LexicalCast.
Moving it into a separate module looks reasonable. It is already
represented as a separate library on the website.
-- Best regards, Antony Polukhin
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk