gcj and '-Wall'?
ADAM Sulmicki
adam@cfar.umd.edu
Sat Apr 1 00:00:00 GMT 2000
It seems that '-Wall' is not supported with gcj.
Is this correct? I was hoping to use gcj to let me
know about any unused variables, and any other possible
bugs..
For that matter, does anyone know any other java compiler which has -Wall
like feature?
bash$ cat hello.c
#include<stdio.h>
main () {
char ch;
printf("hello\n");
}
bash$ gcc -Wall hello.c
hello.c:2: warning: return-type defaults to `int'
hello.c: In function `main':
hello.c:3: warning: unused variable `ch'
hello.c:5: warning: control reaches end of non-void function
bash$ cat HelloWorld.java
public class HelloWorld {
public static void main(String [] args) {
char ch;
System.out.println("Hello");
}
}
bash$ gcj -Wall --main=HelloWorld HelloWorld.java
bash$
More information about the Java
mailing list