Java illegal character: \65279 solution

In the idea, a .java file copied under another project was introduced.
When running Maven Build, it does not pass, and an error is displayed:
Illegal characters in line 1, column x: \65279 I saw
the source file without these things .
utf-8), then delete the original file, recreate a java file with the same name, and copy the text in Notepad to the new file. Save, and then execute maven everything is OK.

Reference address:

Guess you like