Skip to content
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

Fix precision issues in Time by avoiding conversions to nanoseconds. #745

Merged
merged 3 commits into from May 21, 2013

Conversation

@tychobrailleur
Copy link
Contributor

@tychobrailleur tychobrailleur commented May 19, 2013

Fixes #652

Calculations using Time are done to the nanosecond. When using dates,
the Unix time converted into nanosecond is too big (in absolute value)
to fit in a long. The idea in this fix is to separate the millisecond
calculation from the nanosecond one to avoid converting these dates
into nanoseconds.

Calculations using Time are done to the nanosecond.  When using dates,
the Unix time converted into nanosecond is too big (in absolute value)
to fit in a `long`.  The idea in this fix is to separate the millisecond
calculation from the nanosecond one to avoid converting these dates
into nanoseconds.
headius added a commit that referenced this pull request May 21, 2013
Fix precision issues in Time by avoiding conversions to nanoseconds.
@headius headius merged commit 7f4335c into jruby:master May 21, 2013
1 check was pending
1 check was pending
@headius
default The Travis CI build is in progress
Details
@headius
Copy link
Member

@headius headius commented May 21, 2013

CI is in a weird state, but your code looks fine. Merging and will test.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

2 participants