ruby-changes:50338
From: normal <ko1@a...>
Date: Sun, 18 Feb 2018 09:38:43 +0900 (JST)
Subject: [ruby-changes:50338] normal:r62453 (trunk): ext/fiddle/lib/fiddle/pack.rb: pack "void *" properly on 32-bit
normal 2018-02-18 09:38:35 +0900 (Sun, 18 Feb 2018) New Revision: 62453 https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=62453 Log: ext/fiddle/lib/fiddle/pack.rb: pack "void *" properly on 32-bit Fixes: r62450 (commit 1aaeeb326e754c5c5db83fbf35f780f729a9dfed) ("long long is a C99ism") Modified files: trunk/ext/fiddle/lib/fiddle/pack.rb Index: ext/fiddle/lib/fiddle/pack.rb =================================================================== --- ext/fiddle/lib/fiddle/pack.rb (revision 62452) +++ ext/fiddle/lib/fiddle/pack.rb (revision 62453) @@ -48,7 +48,7 @@ module Fiddle https://github.com/ruby/ruby/blob/trunk/ext/fiddle/lib/fiddle/pack.rb#L48 ALIGN_MAP[TYPE_LONG_LONG] = ALIGN_MAP[-TYPE_LONG_LONG] = ALIGN_LONG_LONG PACK_MAP[TYPE_LONG_LONG] = PACK_MAP[-TYPE_LONG_LONG] = "q" SIZE_MAP[TYPE_LONG_LONG] = SIZE_MAP[-TYPE_LONG_LONG] = SIZEOF_LONG_LONG - PACK_MAP[TYPE_VOIDP] = PACK_MAP[TYPE_LONG_LONG] # override + PACK_MAP[TYPE_VOIDP] = "q" if SIZEOF_LONG_LONG == SIZEOF_VOIDP end def align(addr, align) -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/