Execute Java code instead of groovy: !!eval-javac:
Compiles and runs code, be it Java statements or Java classes.
!!eval-javac: (code)
We need this because Groovy isn't of Java syntax, plus it doesn't support JDK8. Using Java code execution will allow running code of the same Java compliance level as the runtime, using JavaCompiler.
Plus, this will be a great opportunity for me to take a break from Vincentyification/JChatExchange, so I'm going to self-assign this and work on it.
- [ ] Execute Java code command:
!!eval-javac: - [ ] Learn a command from the user:
!!learn - [ ] Execute code from online
might be interesting to integrate code compiled like this to a !!learn command for later use
Good idea, I like that a lot. Following that we should also establish running code from gists, pastebin and pastie. For now I'll do it in the following order:
- Execute Java code command:
!!eval-javac: - Learn a command from the user:
!!learn - Execute code from online
Which I also added as a checklist to the main post.
This will deprecate the old !!java-command, right?
It never worked properly anyway. I've never been able to compile a class.
Then I'll just kick that out in my current working branch ;)