Skip to content

Commit

Permalink
Backport 2.5 date.jar change for synergy.
Browse files Browse the repository at this point in the history
Cherry picked from: f9a47c6

Load DateLibrary from date.rb.

I'm not sure how this was lost before. It may have been booted
elsewhere and that code disappeared.
headius committed Feb 23, 2018
1 parent a35d850 commit 7924a80
Showing 2 changed files with 2 additions and 3 deletions.
1 change: 1 addition & 0 deletions core/src/main/java/org/jruby/Ruby.java
Original file line number Diff line number Diff line change
@@ -1741,6 +1741,7 @@ private void initBuiltins() {
addLazyBuiltin("fcntl.rb", "fcntl", "org.jruby.ext.fcntl.FcntlLibrary");
addLazyBuiltin("pathname.jar", "pathname", "org.jruby.ext.pathname.PathnameLibrary");
addLazyBuiltin("set.rb", "set", "org.jruby.ext.set.SetLibrary");
addLazyBuiltin("date.jar", "date", "org.jruby.ext.date.DateLibrary");

addLazyBuiltin("mathn/complex.jar", "mathn/complex", "org.jruby.ext.mathn.Complex");
addLazyBuiltin("mathn/rational.jar", "mathn/rational", "org.jruby.ext.mathn.Rational");
4 changes: 1 addition & 3 deletions lib/ruby/stdlib/date.rb
Original file line number Diff line number Diff line change
@@ -194,6 +194,7 @@
# puts secs_to_new_year()

require 'date/format'
require 'date.jar'

# Class representing a date.
#
@@ -1948,7 +1949,4 @@ def to_datetime

private_class_method :today
public_class_method :now

# Adds native implemented methods...
org.jruby.ext.date.DateLibrary.new.load JRuby.runtime, false
end

0 comments on commit 7924a80

Please sign in to comment.