summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2019-06-13 16:08:22 +0900
committerHiroshi SHIBATA <hsbt@ruby-lang.org>2019-10-24 19:34:36 +0900
commit30d46966a97968d166f2f1440f227c2b52483780 (patch)
treebcd1a55b18916d1d8766a9f6474c0fa66c49ff2f
parent4d844cbaed518743776594fa5ae33b86fe176ad1 (diff)
[ruby/fiddle] Use RbConfig::SIZEOF (#19)
https://github.com/ruby/fiddle/commit/ea06b28db8
-rw-r--r--test/fiddle/helper.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/fiddle/helper.rb b/test/fiddle/helper.rb
index d6fc44af4b6..ad43e3d6787 100644
--- a/test/fiddle/helper.rb
+++ b/test/fiddle/helper.rb
@@ -19,7 +19,7 @@ when /android/
libm_so = File.join(libdir, "libm.so")
when /linux/
libdir = '/lib'
- case [0].pack('L!').size
+ case RbConfig::SIZEOF['void*']
when 4
# 32-bit ruby
libdir = '/lib32' if File.directory? '/lib32'
@@ -53,7 +53,7 @@ when /bsd|dragonfly/
libm_so = "/usr/lib/libm.so"
when /solaris/
libdir = '/lib'
- case [0].pack('L!').size
+ case RbConfig::SIZEOF['void*']
when 4
# 32-bit ruby
libdir = '/lib' if File.directory? '/lib'