[#20036] Re: Roundoff problem with Float and Marshal — matz@... (Yukihiro Matsumoto)

まつもと ゆきひろです

16 messages 2003/04/18
[#20045] Re: Roundoff problem with Float and Marshal — nobu.nakada@... 2003/04/20

なかだです。

[#20063] Re: Roundoff problem with Float and Marshal — matz@... (Yukihiro Matsumoto) 2003/04/22

まつもと ゆきひろです

[#20097] jcode.rb — akira yamada / やまだあきら <akira@...>

25 messages 2003/04/26
[#20098] Re: jcode.rb — matz@... (Yukihiro Matsumoto) 2003/04/27

まつもと ゆきひろです

[#20105] Re: jcode.rb — WATANABE Hirofumi <eban@...> 2003/04/28

わたなべです。

[#20108] Re: jcode.rb — matz@... (Yukihiro Matsumoto) 2003/04/28

まつもと ゆきひろです

[ruby-dev:20036] Re: Roundoff problem with Float and Marshal

From: matz@... (Yukihiro Matsumoto)
Date: 2003-04-18 14:52:36 UTC
List: ruby-dev #20036
まつもと ゆきひろです

In message "Re: Roundoff problem with Float and Marshal"
    on 03/04/18, nobu.nokada@softhome.net <nobu.nokada@softhome.net> writes:

|> Interesting.  Is this endian safe, i.e. does this work properly on
|> both little endian and big endian machine?
|
|No, unfortunately, and assuming binary format is less portable.

あ、やっぱり。

|> If it is endian safe, then we can put mantissa bits at the tail of
|> float representation, e.g. "2.3847655 \001\001", to make it work well
|> with older Marshal.
|
|Implemented with "\0" separator.

これはポータビリティがあるんでしたらこれでいきましょう。

In This Thread

Prev Next