While trying to build a project using intelliJ Ultimate 12 I am getting these errors
use -source or higher to enable diamond operator use -source 7 or higher
For me, it's because the maven-compiler-plugin's source and target is set to 1.6 rather than 1.7 in pom.xml, changing it to 1.7 solved the problem.
maven-compiler-plugin
source
target
pom.xml
maven-compiler-plugin 3.0 1.7 1.7