-
Notifications
You must be signed in to change notification settings - Fork 5.4k
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
Array.indexOf() returns -1 for negative integers which exist in arrays of length >= 48 #27322
Comments
Is this on windows? (is the docker container windows as well?) |
tested locally on ubuntu and in docker. i don't have a windows machine available for testing. |
How did you install Deno? |
using the installer |
Sorry, last question, are you on x86 or aarch64? It's strange because I've been able to see weird behaviour on Windows, but nowhere else. |
x86_64. a very old i5-3470 to be exact |
This looks like a bug in V8, could you please report it here: https://issues.chromium.org/issues/wizard |
I went back through Deno official builds (Windows) and can confirm that this bug has existed since Deno v1.33. I cannot reproduce on Deno v1.32.5 and earlier. |
Version: Deno 2.1.3
poc:
when run under node with:
[copy and paste poc code above]
[ctrl-d]
the
index
andindexOf
always correctly matchwhen run under deno with:
docker run -it denoland/deno repl
[copy and paste poc code above]
indexOf
is -1 when the array is of length>=50 and we're searching for an item whose value is a negative integerfind the array size at which the bug occurs:
this works as expected under node but starts getting indexOf===-1 at length 48 in deno.
The text was updated successfully, but these errors were encountered: