-
Notifications
You must be signed in to change notification settings - Fork 59
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use DiffTime instead of NominalDiffTime #27
Comments
Why use either? Why not just specify using a simple Word64? Seems rather excessive to incur a dependency for just (Nominal)DiffTime? (I'm obviously assuming that there's some way of getting at the system's monotonic clock.) |
What's the issue with a dependency in order to be more expressive in your type system by using a de facto standard? |
How is it more expressive? AFAICT (Nominal)DiffTime even allow negative values -- which is utterly nonsensical for timeouts. (Also, there are other time libraries, though they usually themselves end up having to depend on time itself. Given the above I just don't it makes sense to have the dependency. That's all.) |
The NominalDiffTime type is intended for manipulation of universal dates, and it does not always represent the same interval of time. The timeout values on the other hand require exactly an interval of time, which is the case in this library. Such values should be represented by the DiffTime type.
The text was updated successfully, but these errors were encountered: