|
Boost : |
Subject: Re: [boost] [thread] Integration with Chrono and DateTime (was: [release][1.52] Release Notes)
From: Andrey Semashev (andrey.semashev_at_[hidden])
Date: 2012-10-13 02:22:46
On Oct 13, 2012 2:02 AM, "Vicente J. Botet Escriba" <
vicente.botet_at_[hidden]> wrote:
>
> Note that Boost.Chrono could be configured as a header only library.
AFAIR, it's not the default, so most if not all distributions include it as
a binary. Is the header-only version equivalent to the compiled one?
> BTW, Boost.Thread depends also on Boost.System. Do you avoid already this
dependency?
No, Boost.System is also used by Boost.Filesystem and Boost.ASIO, which I
also use. And I probably catch and throw Boost.System exceptions somewhere
in my code as well.
>>> Me too, I want to limit dependencies :)
>>
>> Fair enough. Perhaps, we could absract away Boost.Thread from both
>> libraries? Seems like a logical solution for a case like this.
>>
>> For example, Boost.Thread could define an internal interface for
>> integrating with time units from different libraries. Chrono and DateTime
>> would support this interface, and Boost.Thread could also provide the
>> necessary glue for std::chrono integration. I think, Boost.Thread could
use
>> its own time units internally and use ADL-found functions to convert from
>> other time units. Boost.Thread will not depend on either timing library
>> then. Does this look viable?
>
> This could be possible but this is not a priority for me, if you want to
provide a patch I will integrate it if the design is simplified, but I
don't see how you could provide the time related function with the
Boost.Chrono interface in this case.
Ok, I will create a Trac ticket then and see what I can do.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk