[erlang-questions] Adding now + interval?

Darach Ennis <>
Wed Nov 26 15:43:34 CET 2014


Converting to milliseconds since the UNIX epoch
and comparing would be simpler and less error
prone IMHO than sticking with the tuple here.

Instead of needing to account for overflow, avoid it.

Cheers,

Darach.

On Wed, Nov 26, 2014 at 2:37 PM, Roger Lipscombe <>
wrote:

> On 26 November 2014 at 13:56, Sergej Jurečko <>
> wrote:
> > Adding 500000 to third element in tuple will work just fine. Unless you
> > really need it to be proper format without overflowing microsecs.
>
> Yeah, I do, otherwise FurtherFuture >= Future won't return the correct
> answer -- as soon as the second element of the tuple is higher (i.e.
> next second), it'll return true, even if 500ms have not yet elapsed.
> _______________________________________________
> erlang-questions mailing list
> 
> http://erlang.org/mailman/listinfo/erlang-questions
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20141126/ffa61504/attachment.html>


More information about the erlang-questions mailing list