[perl #116280] [BUG] NaN, Inf, -Inf aren't padded with spaces in sprintf in Rakudo

2015-11-11 Thread Christian Bartolomaeus via RT
Tests were unfudged with commit https://github.com/perl6/roast/commit/5c7ae5c3f5 and https://github.com/perl6/roast/commit/53e1022caf. I'm closing this ticket as 'resolved'.

[perl #116280] [BUG] NaN, Inf, -Inf aren't padded with spaces in sprintf in Rakudo

2015-11-10 Thread Christian Bartolomaeus via RT
With the next version bump for nqp this will be fixed: $ perl6-m -e 'say sprintf "%12.5f", -Inf' -Inf $ perl6-m -e 'say sprintf "%12.5f", NaN' NaN

Re: [perl #116280] [BUG] NaN, Inf, -Inf aren't padded with spaces in sprintf in Rakudo

2013-01-09 Thread Nicholas Clark
On Wed, Jan 09, 2013 at 10:07:21AM +, Nicholas Clark wrote: > I think that the right way to go is to write sprintf, or as much of it as is > possible, in NQP. Specifically, I suspect that all the parsing of the % codes > should be done in high level language, only kicking down to something low

Re: [perl #116280] [BUG] NaN, Inf, -Inf aren't padded with spaces in sprintf in Rakudo

2013-01-09 Thread Nicholas Clark
On Tue, Jan 08, 2013 at 10:54:44PM +0100, Jonathan Worthington wrote: > On 1/8/2013 22:38, Patrick R. Michaud wrote: > > I wonder what it would take to write a version of sprintf in Perl 6 or > > NQP directly, ignoring all speed aspects for the time being. Then we'd > > at least have something po

Re: [perl #116280] [BUG] NaN, Inf, -Inf aren't padded with spaces in sprintf in Rakudo

2013-01-08 Thread Patrick R. Michaud
On Tue, Jan 08, 2013 at 05:02:21PM -0500, Will Coleda wrote: > Is now a good time to ask if we still want to use the sprintf > slang in perl 6? Yes, see also https://github.com/perl6/specs/issues/13 . Pm

Re: [perl #116280] [BUG] NaN, Inf, -Inf aren't padded with spaces in sprintf in Rakudo

2013-01-08 Thread Will Coleda
Is now a good time to ask if we still want to use the sprintf slang in perl 6? On Tue, Jan 8, 2013 at 4:54 PM, Jonathan Worthington wrote: > On 1/8/2013 22:38, Patrick R. Michaud wrote: > >> I wonder what it would take to write a version of sprintf in Perl 6 or >> NQP directly, ignoring all spee

Re: [perl #116280] [BUG] NaN, Inf, -Inf aren't padded with spaces in sprintf in Rakudo

2013-01-08 Thread Jonathan Worthington
On 1/8/2013 22:38, Patrick R. Michaud wrote: I wonder what it would take to write a version of sprintf in Perl 6 or NQP directly, ignoring all speed aspects for the time being. Then we'd at least have something portable, provably correct, easily modified, and that could be used as a reference i

Re: [perl #116280] [BUG] NaN, Inf, -Inf aren't padded with spaces in sprintf in Rakudo

2013-01-08 Thread Patrick R. Michaud
On Tue, Jan 08, 2013 at 11:52:12AM -0800, Carl Mäsak via RT wrote: > On Tue Jan 08 11:40:37 2013, FROGGS.de wrote: > > This would mean to bring over 500 lines of C code to nqp/rakudo. > > Is that an absolute claim? What about wrappers? Currently Rakudo uses Parrot's sprintf features. I wouldn't

[perl #116280] [BUG] NaN, Inf, -Inf aren't padded with spaces in sprintf in Rakudo

2013-01-08 Thread Carl Mäsak via RT
On Tue Jan 08 11:40:37 2013, FROGGS.de wrote: > This would mean to bring over 500 lines of C code to nqp/rakudo. Is that an absolute claim? What about wrappers? > And this would mean that it doesn't get faster. Is it worth it? In my mind, correctness trumps speed. The current behavior seems obv

[perl #116280] [BUG] NaN, Inf, -Inf aren't padded with spaces in sprintf in Rakudo

2013-01-03 Thread Carl Mäsak
# New Ticket Created by "Carl Mäsak" # Please include the string: [perl #116280] # in the subject line of all future correspondence about this issue. # https://rt.perl.org:443/rt3/Ticket/Display.html?id=116280 > rn: say sprintf '%12.5f', NaN rakudo f5037e: OUTPUT«NaN␤» ..niecza v24-12-g8e5