From http://mail.openjdk.java.net/pipermail/nashorn-dev/2013-October/002139.html