切换java版本

First, clean your project:

Project > Clean

If that doesn't fix things...

Second check your project specific java compiler:

Project > Properties > Java Compiler

原文地址:https://www.cnblogs.com/kakaisgood/p/7999797.html