I've been trying to fix a broken test in the dl test suite, but I'm
concerned about the patch.  The original test calls the sin() function,
but packs and unpacks the number before calling the function.

I'm not sure why that is necessary, and removing the pack / unpack
sequence seems to fix the test.  I assume the pack / unpack is for
dealing with platform differences, but after applying this patch, the
test passes on x86_64 and ppc platforms.

diff --git test/dl/test_dl2.rb test/dl/test_dl2.rb
index ac14149..508b50b 100644
--- test/dl/test_dl2.rb
+++ test/dl/test_dl2.rb
@@ -91,11 +91,11 @@ class TestDL < TestBase
   def test_sin()
     pi_2 = Math::PI/2
     cfunc = CFunc.new(@libm['sin'], TYPE_DOUBLE, 'sin')
-    x = cfunc.call([pi_2].pack("d").unpack("l!*"))
+    x = cfunc.call([pi_2])
     assert_equal(Math.sin(pi_2), x)
 
     cfunc = CFunc.new(@libm['sin'], TYPE_DOUBLE, 'sin')
-    x = cfunc.call([-pi_2].pack("d").unpack("l!*"))
+    x = cfunc.call([-pi_2])
     assert_equal(Math.sin(-pi_2), x)
   end
 
-- 
Aaron Patterson
http://tenderlovemaking.com/