This is a minor issue and not necessarily a bug to be reported. When I create a file using the classless approach such as:
void main() { println("Mooses rule!"); } It will run with the --enable-preview VM option. Great! Unfortunately, all that Source -> Formatting does is add a blank line at the top of the file and nothing more. I assume it is looking for something it can identify as a class otherwise it does not format the file. Ken