Eclipse and assert  
Author Message
higgledy





PostPosted: 2006-3-17 4:07:00 Top

java-programmer, Eclipse and assert I am using Eclipse. I want to enable assert in my code. I alrready have
the compiler set to use Jave 5.0. How do I configure the build and run
to use the correct switch to enable assert evaluations?

 
Xavier Tarrago





PostPosted: 2006-3-17 16:29:00 Top

java-programmer >> Eclipse and assert Menu Windows.Preferences ->
uncheck "Use default compliance setting"
select 1.4, 1.4, "Error", "Warning"

It should also work with 5.0 settings, but I use the above and it works...


"higgledy" <email***@***.com> a 閏rit dans le message de
news:email***@***.com...
> I am using Eclipse. I want to enable assert in my code. I alrready have
> the compiler set to use Jave 5.0. How do I configure the build and run
> to use the correct switch to enable assert evaluations?
>


 
Xavier Tarrago





PostPosted: 2006-3-17 16:32:00 Top

java-programmer >> Eclipse and assert Sorry...
To enable assertions, run with -ea command line option. I think that you can
be more specific with some -ea:my.package

"higgledy" <email***@***.com> a 閏rit dans le message de
news:email***@***.com...
> I am using Eclipse. I want to enable assert in my code. I alrready have
> the compiler set to use Jave 5.0. How do I configure the build and run
> to use the correct switch to enable assert evaluations?
>