develooper Front page | perl.cvs.parrot | Postings from December 2008

[svn:parrot] r34214 - trunk/languages/perl6/src/builtins

From:
pmichaud
Date:
December 21, 2008 09:15
Subject:
[svn:parrot] r34214 - trunk/languages/perl6/src/builtins
Message ID:
20081221171521.47E49CBA12@x12.develooper.com
Author: pmichaud
Date: Sun Dec 21 09:15:20 2008
New Revision: 34214

Modified:
   trunk/languages/perl6/src/builtins/any-list.pir

Log:
[rakudo]:  Add +Inf and -Inf to min and max (RT #60868, cspencer++)
* Patch courtesy Cory Spencer.


Modified: trunk/languages/perl6/src/builtins/any-list.pir
==============================================================================
--- trunk/languages/perl6/src/builtins/any-list.pir	(original)
+++ trunk/languages/perl6/src/builtins/any-list.pir	Sun Dec 21 09:15:20 2008
@@ -246,7 +246,9 @@
     result = $P0
     goto loop
   fail:
-    result = 'undef'()
+    .local num failres
+    failres = "+Inf"
+    .return (failres)
   done:
     .return (result)
 .end
@@ -288,7 +290,9 @@
     result = $P0
     goto loop
   fail:
-    result = 'undef'()
+    .local num failres
+    failres = "-Inf"
+    .return (failres)
   done:
     .return (result)
 .end



nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About