This should not compile.
static import java.lang.System.out;
According to JLS, one static import should look like this:
import static java.lang.System.out;
All forms of the Java import statement begin with the import keyword, and I don’t think there is any other context (that is, besides the import statement) in which you can use the import keyword.
Note: the keywords import and static are not modifiers in this context, so the "modifiers can be provided in any order" meta-rule does not apply here.
In short, your compiler / IDE is broken or confused ... or what you are looking at is not real Java source code.
source share