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

Safari 10.1 array modifying methods bug? #449

Open
Xotic750 opened this issue Sep 28, 2017 · 3 comments
Open

Safari 10.1 array modifying methods bug? #449

Xotic750 opened this issue Sep 28, 2017 · 3 comments

Comments

@Xotic750
Copy link
Contributor

Xotic750 commented Sep 28, 2017

https://bugs.webkit.org/show_bug.cgi?id=170264

Can be detected and fixed I believe? Quite large numbers of people affected that are using libraries such as big.js, bignumber.js and decimal.js. MikeMcl/bignumber.js#120

Anyway, just a heads up.

@ljharb
Copy link
Member

ljharb commented Sep 29, 2017

Here's the test webkit uses: https://bugs.webkit.org/attachment.cgi?id=306201&action=diff#JSTests/stress/double-array-to-array-storage.js_sec1

I'm not sure if it can be fixed, since it was a bug in the C++ JSObject inside webkit. I'll leave this open just in case tho.

@Xotic750
Copy link
Contributor Author

I'm not sure how much it affects all array things on the whole, I do know that it can be detected and certain work-arounds for specific use cases can be implemented, but I don't know if a general fix for methods can be applied.

@Xotic750
Copy link
Contributor Author

Xotic750 commented Oct 1, 2017

I had a look to see what could be done about this, whether there was a global fix that could done. I didn't find a way, but it did come up with this

https://github.com/Xotic750/create-array-fix-x

But can't test it because I have no access to Safari :( Thought I'd just post the info in case it comes in useful. :)

https://rawgit.com/Xotic750/create-array-fix-x/master/tests/index.html

It's by no means fully working (methods that return arrays are not correct), but it does show what could be possible, with a little more work.

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

2 participants