ruby-changes:7821
From: tadf <ko1@a...>
Date: Sun, 14 Sep 2008 18:35:23 +0900 (JST)
Subject: [ruby-changes:7821] Ruby:r19342 (trunk): * complex.c: trivial changes.
tadf 2008-09-14 18:35:08 +0900 (Sun, 14 Sep 2008) New Revision: 19342 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=19342 Log: * complex.c: trivial changes. Modified files: trunk/ChangeLog trunk/complex.c trunk/rational.c Index: complex.c =================================================================== --- complex.c (revision 19341) +++ complex.c (revision 19342) @@ -377,13 +377,15 @@ switch (rb_scan_args(argc, argv, "11", &real, &image)) { case 1: + nucomp_real_check(real); image = ZERO; break; + default: + nucomp_real_check(real); + nucomp_real_check(image); + break; } - nucomp_real_check(real); - nucomp_real_check(image); - return nucomp_s_canonicalize_internal(klass, real, image); } #endif @@ -395,13 +397,15 @@ switch (rb_scan_args(argc, argv, "11", &real, &image)) { case 1: + nucomp_real_check(real); image = ZERO; break; + default: + nucomp_real_check(real); + nucomp_real_check(image); + break; } - nucomp_real_check(real); - nucomp_real_check(image); - return nucomp_s_canonicalize_internal(klass, real, image); } @@ -1125,9 +1129,8 @@ } if (NIL_P(m)) { m = f_match(comp_pat2, s); - if (NIL_P(m)) { + if (NIL_P(m)) return rb_assoc_new(Qnil, self); - } sr = f_aref(m, INT2FIX(1)); if (NIL_P(f_aref(m, INT2FIX(2)))) si = Qnil; @@ -1495,5 +1498,5 @@ /* Local variables: c-file-style: "ruby" -end: +End: */ Index: ChangeLog =================================================================== --- ChangeLog (revision 19341) +++ ChangeLog (revision 19342) @@ -1,3 +1,7 @@ +Sun Sep 14 18:33:32 2008 Tadayoshi Funaba <tadf@d...> + + * complex.c: trivial changes. + Sun Sep 14 16:15:22 2008 Yuki Sonoda (Yugui) <yugui@y...> * lib/matrix.rb (Vector#eql?): typo of the method name as "eqn?". Index: rational.c =================================================================== --- rational.c (revision 19341) +++ rational.c (revision 19342) @@ -1596,5 +1596,5 @@ /* Local variables: c-file-style: "ruby" -end: +End: */ -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/