Skip to content
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

Weird infinite ranges: Inf..0, -Inf..0 and NaN..0 #4297

Closed
p6rt opened this issue Jun 5, 2015 · 6 comments
Closed

Weird infinite ranges: Inf..0, -Inf..0 and NaN..0 #4297

p6rt opened this issue Jun 5, 2015 · 6 comments

Comments

@p6rt
Copy link

p6rt commented Jun 5, 2015

Migrated from rt.perl.org#125336 (status was 'resolved')

Searchable as RT125336$

@p6rt
Copy link
Author

p6rt commented Jun 5, 2015

From @AlexDaniel

Code​:
.say for Inf..0

Result​:
-9223372036854775808
-9223372036854775808
-9223372036854775808
-9223372036854775808
... and so on (infinitely) ...

Code​:
.say for -Inf..0
Result​:
-Inf
-Inf
-Inf
-Inf
... and so on exactly 1024 times, but then suddenly​:
-9223372036854775808
-9223372036854775808
-9223372036854775808
-9223372036854775808
... and so on (infinitely) ...

Code​:
.say for NaN..0
Result​:
-Inf
-Inf
-Inf
-Inf
... and so on exactly 1024 times, but then suddenly​:
-9223372036854775808
-9223372036854775808
-9223372036854775808
-9223372036854775808
... and so on (infinitely) ...

@p6rt
Copy link
Author

p6rt commented Jun 5, 2015

From @AlexDaniel

A little correction for 「.say for NaN..0」 -- it prints 1024 NaNs, not
-Infs.

Code​:
.say for NaN..0
Result​:
NaN
NaN
NaN
NaN
... and so on exactly 1024 times, but then suddenly​:
-9223372036854775808
-9223372036854775808
-9223372036854775808
-9223372036854775808
... and so on (infinitely) ...

Also, here is another one that actually *counts up*!
Code​:
.say for NaN..NaN

Result​:
NaN
NaN
NaN
NaN
... and so on exactly 1024 times, but then suddenly​:
-9223372036854775808
-9223372036854775807
-9223372036854775806
-9223372036854775805
... and so on ...

On Fri, Jun 5, 2015 at 7​:18 PM, perl6 via RT <perl6-bugs-followup@​perl.org>
wrote​:

Greetings,

This message has been automatically generated in response to the
creation of a trouble ticket regarding​:
"Weird infinite ranges​: Inf..0, -Inf..0 and NaN..0",
a summary of which appears below.

There is no need to reply to this message right now. Your ticket has been
assigned an ID of [perl #​125336].

Please include the string​:

     \[perl #&#8203;125336\]

in the subject line of all future correspondence about this issue. To do
so,
you may reply to this message.

                    Thank you,
                    perl6\-bugs\-followup@&#8203;perl\.org

-------------------------------------------------------------------------
Code​:
.say for Inf..0

Result​:
-9223372036854775808
-9223372036854775808
-9223372036854775808
-9223372036854775808
... and so on (infinitely) ...

Code​:
.say for -Inf..0
Result​:
-Inf
-Inf
-Inf
-Inf
... and so on exactly 1024 times, but then suddenly​:
-9223372036854775808
-9223372036854775808
-9223372036854775808
-9223372036854775808
... and so on (infinitely) ...

Code​:
.say for NaN..0
Result​:
-Inf
-Inf
-Inf
-Inf
... and so on exactly 1024 times, but then suddenly​:
-9223372036854775808
-9223372036854775808
-9223372036854775808
-9223372036854775808
... and so on (infinitely) ...

@p6rt
Copy link
Author

p6rt commented Oct 2, 2017

From @AlexDaniel

I think that this stuff is resolved. Not sure when exactly because bisectable is refusing to work today, but this is TESTNEEDED.

On 2015-06-05 09​:18​:44, alex.jakimenko@​gmail.com wrote​:

Code​:
.say for Inf..0

Result​:
-9223372036854775808
-9223372036854775808
-9223372036854775808
-9223372036854775808
... and so on (infinitely) ...

Code​:
.say for -Inf..0
Result​:
-Inf
-Inf
-Inf
-Inf
... and so on exactly 1024 times, but then suddenly​:
-9223372036854775808
-9223372036854775808
-9223372036854775808
-9223372036854775808
... and so on (infinitely) ...

Code​:
.say for NaN..0
Result​:
-Inf
-Inf
-Inf
-Inf
... and so on exactly 1024 times, but then suddenly​:
-9223372036854775808
-9223372036854775808
-9223372036854775808
-9223372036854775808
... and so on (infinitely) ...

@p6rt
Copy link
Author

p6rt commented Oct 3, 2017

From @AlexDaniel

The problem went away during the glr. Bisectable points to 96 candidates, so nothing useful there.

On 2017-10-01 23​:15​:28, alex.jakimenko@​gmail.com wrote​:

I think that this stuff is resolved. Not sure when exactly because
bisectable
is refusing to work today, but this is TESTNEEDED.

On 2015-06-05 09​:18​:44, alex.jakimenko@​gmail.com wrote​:

Code​:
.say for Inf..0

Result​:
-9223372036854775808
-9223372036854775808
-9223372036854775808
-9223372036854775808
... and so on (infinitely) ...

Code​:
.say for -Inf..0
Result​:
-Inf
-Inf
-Inf
-Inf
... and so on exactly 1024 times, but then suddenly​:
-9223372036854775808
-9223372036854775808
-9223372036854775808
-9223372036854775808
... and so on (infinitely) ...

Code​:
.say for NaN..0
Result​:
-Inf
-Inf
-Inf
-Inf
... and so on exactly 1024 times, but then suddenly​:
-9223372036854775808
-9223372036854775808
-9223372036854775808
-9223372036854775808
... and so on (infinitely) ...

@p6rt
Copy link
Author

p6rt commented Oct 13, 2017

From @zoffixznet

Tests​: Raku/roast@bfc143e0ac

@p6rt
Copy link
Author

p6rt commented Oct 13, 2017

@zoffixznet - Status changed from 'new' to 'resolved'

@p6rt p6rt closed this as completed Oct 13, 2017
@p6rt p6rt added the testneeded label Jan 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant