aemkei / jsfuck

Write any JavaScript with 6 Characters: []()!+
jsfuck.com
Do What The F*ck You Want To Public License
8.16k stars 674 forks source link

Expression not evaluated #3

Open eonj opened 11 years ago

eonj commented 11 years ago

As far as I know, eval("0") is 0. However, I must write "return 0;" instead of "0" when I want to get Number 0 for the return. Same for any expression like /0-9A-Za-z/g. If it is not intended, this is not an exact eval().

I suggest for eval:

[]["filter"]["constructor"]("return eval(CODE)")()