I tried getting it to work under 7 previously and was met by the same error as you have. I think it has to do with the fact that Nashorn makes use of some new features in Java 8.
There is a backport of Nashorn for JDK 7 on bitbucket; I wrote a blog post detailing how to use it on my works blog here. You can also look at this stack overflow question for more information.
That bitbucket project hasn't been updated in some time, I'd recommend that you use the preview of Java 8 if you want to play with Nashorn.