[macruby-changes] [1008] MacRuby/branches/experimental

source_changes at macosforge.org source_changes at macosforge.org
Thu Mar 19 23:42:55 PDT 2009


Revision: 1008
          http://trac.macosforge.org/projects/ruby/changeset/1008
Author:   vincent.isambart at gmail.com
Date:     2009-03-19 23:42:52 -0700 (Thu, 19 Mar 2009)
Log Message:
-----------
corrected an incorrect test case and the code that did the wrong thing

Modified Paths:
--------------
    MacRuby/branches/experimental/roxor.cpp
    MacRuby/branches/experimental/test_roxor.rb

Modified: MacRuby/branches/experimental/roxor.cpp
===================================================================
--- MacRuby/branches/experimental/roxor.cpp	2009-03-20 06:41:13 UTC (rev 1007)
+++ MacRuby/branches/experimental/roxor.cpp	2009-03-20 06:42:52 UTC (rev 1008)
@@ -5033,7 +5033,7 @@
 
     if (dvars_size > 0 || argc < arity.min || argc > arity.max) {
 	VALUE *new_argv;
-	if (argc == 1 && TYPE(argv[0]) == T_ARRAY && (arity.max == -1 || arity.max > 1)) {
+	if (argc == 1 && TYPE(argv[0]) == T_ARRAY && arity.max > 1) {
 	    // Expand the array
 	    long ary_len = RARRAY_LEN(argv[0]);
 	    new_argv = (VALUE *)alloca(sizeof(VALUE) * ary_len);

Modified: MacRuby/branches/experimental/test_roxor.rb
===================================================================
--- MacRuby/branches/experimental/test_roxor.rb	2009-03-20 06:41:13 UTC (rev 1007)
+++ MacRuby/branches/experimental/test_roxor.rb	2009-03-20 06:42:52 UTC (rev 1008)
@@ -812,7 +812,7 @@
     def foo; yield(1, 2); end
     foo { |*rest| p rest }
   }
-  assert "[1, 2]", %q{
+  assert "[[1, 2]]", %q{
     def foo; yield([1, 2]); end
     foo { |*rest| p rest }
   }
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macruby-changes/attachments/20090319/e313709e/attachment.html>


More information about the macruby-changes mailing list