New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
NaN, Inf, -Inf aren't padded with spaces in sprintf in Rakudo #3019
Comments
From @masak<masak> rn: say sprintf '%12.5f', NaN Modulo Niecza's preference for "Infinity" instead of "Inf", I believe <masak> rn: say sprintf '%12.5f', 42 |
From @FROGGSThis would mean to bring over 500 lines of C code to nqp/rakudo. And this would mean that it doesn't get faster. Is it worth it? |
The RT System itself - Status changed from 'new' to 'open' |
From @masakOn Tue Jan 08 11:40:37 2013, FROGGS.de wrote:
Is that an absolute claim? What about wrappers?
In my mind, correctness trumps speed. The current behavior seems |
From @pmichaudOn Tue, Jan 08, 2013 at 11:52:12AM -0800, Carl Mäsak via RT wrote:
Currently Rakudo uses Parrot's sprintf features. I wouldn't
Agreed. There are rare times when "fast but incorrect" is Beyond that, we ultimately will have to solve the formatted I wonder what it would take to write a version of sprintf in Pm |
From @jnthnOn 1/8/2013 22:38, Patrick R. Michaud wrote:
/jnthn |
From @cokeIs now a good time to ask if we still want to use the sprintf slang in perl On Tue, Jan 8, 2013 at 4:54 PM, Jonathan Worthington <jonathan@jnthn.net>wrote:
-- |
From @pmichaudOn Tue, Jan 08, 2013 at 05:02:21PM -0500, Will Coleda wrote:
Yes, see also Raku/old-design-docs#13 . Pm |
From @nwc10On Tue, Jan 08, 2013 at 10:54:44PM +0100, Jonathan Worthington wrote:
I think that the right way to go is to write sprintf, or as much of it as is It's going to end up being a) faster to write http://morepypy.blogspot.com/2011/08/pypy-is-faster-than-c-again-string.html Nicholas Clark |
From @nwc10On Wed, Jan 09, 2013 at 10:07:21AM +0000, Nicholas Clark wrote:
s/decimals/integers/ Which probably is just %d, or %d and %x I'm going to quote this again :-)
Nicholas Clark |
From @FROGGStests are at Raku/roast@2647c16652 |
From @usev6Current behaviour as a status update: $ perl6-m -e 'say sprintf "%12.5f", NaN' ## similiar for Inf and -Inf $ perl6-p -e 'say sprintf "%12.5f", Inf' ## similiar for NaN and -Inf $ perl6-j -e 'say sprintf "%12.5f", -Inf' ## similiar for NaN and Inf I'll adjusted the fudging in S32-str/sprintf.t (e.g. perl6-p no longer hangs). |
From @usev6With the next version bump for nqp this will be fixed: $ perl6-m -e 'say sprintf "%12.5f", -Inf' $ perl6-m -e 'say sprintf "%12.5f", NaN' |
1 similar comment
From @usev6With the next version bump for nqp this will be fixed: $ perl6-m -e 'say sprintf "%12.5f", -Inf' $ perl6-m -e 'say sprintf "%12.5f", NaN' |
From @usev6Tests were unfudged with commit Raku/roast@5c7ae5c3f5 and Raku/roast@53e1022caf. I'm closing this ticket as 'resolved'. |
1 similar comment
From @usev6Tests were unfudged with commit Raku/roast@5c7ae5c3f5 and Raku/roast@53e1022caf. I'm closing this ticket as 'resolved'. |
@usev6 - Status changed from 'open' to 'resolved' |
Migrated from rt.perl.org#116280 (status was 'resolved')
Searchable as RT116280$
The text was updated successfully, but these errors were encountered: