Static import

I there :slight_smile:
I’ve got some problems using static imports (I’m using the 1.5beta JDK). Here are my imports code :


import org.lwjgl.*;
import org.lwjgl.input.*;
import org.lwjgl.opengl.*;
import org.lwjgl.opengl.glu.*;

import static org.lwjgl.opengl.GL11.*;

But when I want to compile my code, I get 2 errors :


<identifier expected>
import static org.lwjgl.opengl.GL11.*;

'.' expected
import static org.lwjgl.opengl.GL11.*;

I can’t find any ressources on the web… Can someone can help me ?
Thanks in advance !

tried import static org.lwjgl.opengl.GL11; ?

Yes i’ve tried it too but I get the same errors…
Even if I compile with


javac -target 1.5 *.java

That’s very strange…

shouldn’t that be javac -source 1.5 ???

Oh thanks now it works :stuck_out_tongue:
Sorry for this stupid mistake !

so what is the correct syntax, finaly ? :slight_smile:

for example:


import static org.lwjgl.opengl.GL11;

and compiling it with javac -source 1.5