A third patch in the DateTime trilogy -- this one provides fallback behavior on Time::Calculations so that a DateTime is returned if the result is out of the range supported by the Ruby Time class (currently, it just returns "ArgumentError: time out of range".)
If all of these patches were added to the trunk (currently, just the first one is), you could then do something like this: Time.now.years_since(32).beginning_of_day ...and then save it to the db with the correct date and time. Would this then make Rails Year-2038-Compliant? http://dev.rubyonrails.org/ticket/7706 Geoff On Mar 2, 9:49 am, "fedot" <[EMAIL PROTECTED]> wrote: > Geoff, this is exactly what I had in mind. Thank you for putting the > patch together. I also added another patch to your ticket for test/ > migration_test.rb ensuring that datetime fields falling below > DateTime's lower limit get read back in as DateTime objects. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en -~----------~----~----~----~------~----~------~--~---
