Bug #3671

DateTime dumped by Marshal from ruby 1.8 cannot be loaded by ruby 1.9

Added by Eric Hodel about 5 years ago. Updated over 4 years ago.

[ruby-core:31659]
Status:Rejected
Priority:Normal
Assignee:tadayoshi funaba
ruby -v:ruby 1.9.3dev (2010-07-07 trunk 28561) [x86_64-darwin10.4.0] Backport:

Description

=begin
$ ruby -rdate -e 'Marshal.dump DateTime.now, $stdout' | ruby19 -rdate -e 'p Marshal.load $stdin.read'
-e:1:in load': class DateTime needs to have method_load' (TypeError)
from -e:1:in `'

$ ruby -v
ruby 1.8.7 (2009-06-12 patchlevel 174) [universal-darwin10.0]
$ ruby19 -v
ruby 1.9.3dev (2010-07-07 trunk 28561) [x86_64-darwin10.4.0]

Ruby 1.9 should implement DateTime._load in order to load from older versions
=end

History

#1 Updated by Yui NARUSE about 5 years ago

  • Assignee set to tadayoshi funaba
  • Target version set to 2.0.0

=begin

=end

#2 Updated by tadayoshi funaba about 5 years ago

  • Status changed from Open to Rejected

=begin
this is not a matter of date.
rational or ruby.

$ /usr/local/bin/ruby -rrational -e 'Marshal.dump Rational(1,2), $stdout' | ./ruby -rrational -e 'p Marshal.load $stdin.read'
-e:1:in load': dump format error (ArgumentError)
from -e:1:in
'

=end

Also available in: Atom PDF