Hacker News new | ask | show | jobs
by jr62 5322 days ago
On Chrome 14 (Linux), when I click "eval" it doesn't show the alert dialog. Even leaving the default text there. It's an interesting concept though, would definitely be good to see an explanation of how it works.
1 comments

If I try copying and pasting the encoded source into Chrome's JS console, it gives the following error:

    TypeError: Array.prototype.sort called on null or undefined.
I would be interested to see what exactly it's doing, and how alert("Hello World"); gets mangled to call Array.prototype.sort().

EDIT: I should note that I get this error no matter what code I put in. I think Chrome's Javascript interpreter is somehow interpreting some of that boilerplate as a call to Array.prototype.sort() somehow.