[#7055] More on VC++ 2005 — Austin Ziegler <halostatue@...>

Okay. I've got Ruby compiling. I'm attempting to get everything in

17 messages 2006/01/05
[#7058] Re: More on VC++ 2005 — nobuyoshi nakada <nobuyoshi.nakada@...> 2006/01/06

Hi,

[#7084] mathn: ugly warnings — hadmut@... (Hadmut Danisch)

Hi,

22 messages 2006/01/10
[#7097] Re: mathn: ugly warnings — Daniel Berger <Daniel.Berger@...> 2006/01/10

Hadmut Danisch wrote:

[#7098] Design contracts and refactoring (was Re: mathn: ugly warnings) — mathew <meta@...> 2006/01/10

Daniel Berger wrote:

[#7118] Re: Design contracts and refactoring (was Re: mathn: ugly warnings) — mathew <meta@...> 2006/01/12

*Dean Wampler *<deanwampler gmail.com> writes:

[#7226] Fwd: Re: Question about massive API changes — "Sean E. Russell" <ser@...>

Hello,

23 messages 2006/01/28
[#7228] Re: Question about massive API changes — Caleb Tennis <caleb@...> 2006/01/28

>

Re: YAML bug - Ruby 1.8.3

From: "H.Yamamoto" <ocean@...2.ccsnet.ne.jp>
Date: 2006-01-10 07:03:20 UTC
List: ruby-core #7092
Hi.

"Jon A. Lambert" <jlsysinc@alltel.net> wrote:
(2005/12/31 13:35)

>$ cat testyaml.rb
>require 'yaml'
>class A
>  def initialize
>    @create = Time.new
>    @date = @create
>  end
>end
>puts YAML::dump(A.new)
>
>$ ruby testyaml.rb
>!ruby/object:A
>create: &id001 2005-12-30 23:20:08.572500 -05:00
>date: *id001
>
>$ ruby --version
>ruby 1.8.3 (2005-09-21) [i386-cygwin]
>
>I still haven't upgraded from Ruby 1.8.2, but many of the users of my 
>software are downloading and installing Ruby 1.8.3.
>Has the above been previously reported and/or fixed in Ruby 1.8.4?
>
>Thanks

Umm, is this bug? 1.8.4 saves object's state more accurately.

require 'yaml'
class A
  def initialize
    @create = Time.new
    @date = @create
  end
  def modify!
    @create.utc
    self
  end
end
p y = YAML::dump(A.new)
p o = YAML::load(y)
p o.modify!

In 1.8.2, only @create becomes utc.
In 1.8.4, both @create and @date becomes utc. (as well as before dumping)


In This Thread