Boost logo

Boost :

Subject: Re: [boost] DateTime conversion to tm problem?
From: Andrey Semashev (andrey.semashev_at_[hidden])
Date: 2009-06-21 17:12:24

Maciej Sobczak wrote:

>> Are there any use cases that will become invalid if the tm_mday will
>> be set to 1?
> Andrey Semashev noted that in the case of duration such a value is
> correct. I would argue, however, that duration and "point in time"
> should be distinct types - "overloading" std::tm for handling durations
> is a bad idea for the reasons explained above.

That's right, but there's no standard type to express durations. And I
agree, to_tm overload for time_duration might not have been a good idea.
I guess, there was a good reason to provide it.

Boost list run by bdawes at, gregod at, cpdaniel at, john at