Re: [PATCH] PR libstdc++/81468 constrain std::chrono::time_point constructor

2017-09-18 Thread Jonathan Wakely
On 13/09/17 21:30 -0400, Tim Song wrote: On Wed, Sep 13, 2017 at 10:55 AM, Jonathan Wakely wrote: +// DR 1177 +static_assert(is_constructible{}, +"can convert duration with one floating point rep to another");

Re: [PATCH] PR libstdc++/81468 constrain std::chrono::time_point constructor

2017-09-13 Thread Tim Song
On Wed, Sep 13, 2017 at 10:55 AM, Jonathan Wakely wrote: > > +// DR 1177 > +static_assert(is_constructible{}, > +"can convert duration with one floating point rep to another"); > +static_assert(is_constructible{}, > +"can convert

Re: [PATCH] PR libstdc++/81468 constrain std::chrono::time_point constructor

2017-09-13 Thread Jonathan Wakely
On 13/09/17 15:09 +0100, Jonathan Wakely wrote: Howard reported this bug, caused by a missing SFINAE constraint on a std::chrono::time_point constructor. I've also done a bit of simplification using alias templates. Here's the backport for the branches, which just adds the constraint (and

[PATCH] PR libstdc++/81468 constrain std::chrono::time_point constructor

2017-09-13 Thread Jonathan Wakely
Howard reported this bug, caused by a missing SFINAE constraint on a std::chrono::time_point constructor. I've also done a bit of simplification using alias templates. PR libstdc++/81468 * include/std/chrono (__enable_if_is_duration) (__disable_if_is_duration): New alias