diff options
author | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-02-26 18:51:02 +0000 |
---|---|---|
committer | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-02-26 18:51:02 +0000 |
commit | 8c9024763f6340d0fc64e21dd6ee052af8c6748b (patch) | |
tree | f1ad29586da4aec8a4b8b3fd265e6c456812afef /include | |
parent | 069d271eb5b237b2274c382c5da011b43b0fa1d9 (diff) | |
download | ruby-8c9024763f6340d0fc64e21dd6ee052af8c6748b.tar.gz |
* pack.c: fix q and Q for big endian environments which have no
8 bytes integer type.
(pack_pack): use rb_big_pack.
(pack_unpack): use rb_big_unpack.
* include/ruby/intern.h (rb_big_pack): declared.
(rb_big_unpack): ditto.
* bignum.c (rb_big_pack): new function.
(rb_big_unpack): ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26771 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'include')
-rw-r--r-- | include/ruby/intern.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/ruby/intern.h b/include/ruby/intern.h index 7872ca8007..ebbdd713b2 100644 --- a/include/ruby/intern.h +++ b/include/ruby/intern.h @@ -103,6 +103,8 @@ unsigned LONG_LONG rb_big2ull(VALUE); #endif /* HAVE_LONG_LONG */ void rb_quad_pack(char*,VALUE); VALUE rb_quad_unpack(const char*,int); +void rb_big_pack(VALUE val, unsigned long *buf, long num_longs); +VALUE rb_big_unpack(unsigned long *buf, long num_longs); int rb_uv_to_utf8(char[6],unsigned long); VALUE rb_dbl2big(double); double rb_big2dbl(VALUE); |