A fun quiz on eval() in JS, and corner cases of its behaviour: https://blog.brownplt.org/2012/10/21/js-eval.html I've seen some of the gotchas before, but I still don't envy JS implementors.