This is the mail archive of the java@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: --disable-assertions does not work when compiling from .class


Em Fri, 02 Sep 2005 16:34:21 +0530, Ranjit Mathew escreveu:

> To implement what you want, GCJ would have to recognise such patterns in
> class files generated by itself, by javac, by ECJ, by Jikes, etc. -
> needless to say, this is rather difficult and does not provide much
> benefit.

So, it would be nice to at least have in the GCJ documentation an
explanation that --disable-assertions is only meaninful when compiling
from source. With the current statement "By default, assertions are
enabled when generating class files or when not optimizing, and disabled
when generating optimized binaries." we think that GCJ will disable
assertions when generating binaries even from .class files, as nothing is
said that it will do differently. 

And why the proprietary JDKs can disable at runtime the use of assertions
(with "java -disableassertions") for .class files generated by javac, ECJ,
Jikes etc. (with the assert portions in it)? Isn't there an agreed
structure for an assertion? 

-- 
Sergio Queiroz


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]