Compiler Crash
Neal Gafter
neal at gafter.com
Thu May 22 14:42:12 PDT 2008
Thanks! As I said, eventually the underlying bug in javac will have to be
fixed.
On Thu, May 22, 2008 at 2:25 PM, Tony Morris <tmorris at tmorris.net> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Hey Neal,
> I just wanted to confirm for you that the BGGA compiler version
> 2008-05-11 no longer exhibits the problem in my non-trivial examples.
>
> Tony Morris
> http://tmorris.net/
>
> Real-world problems are simply degenerate cases of pure mathematical
> problems.
>
>
>
> Neal Gafter wrote:
> > On Thu, May 8, 2008 at 10:11 PM, Neal Gafter <neal at gafter.com> wrote:
> >
> >> Thank you! I'll tell you as soon as I've pushed a fixed version of the
> >> prototype.
> >
> >
> > Long story short: this is a symptom of a latent bug in javac (I've filed
> a
> > bug report). I have updated the prototype to work around it to prevent
> the
> > crash, but the bug will have to be fixed in the core compiler eventually.
> > Below is a javac regression test that demonstrates a symptom of the
> > underlying problem in the SE 6 javac. Compile with -Xlint:divzero. You
> > should get no warning but the compiler does produce a warning.
> >
> > */*
> >
> > *
> > @test
> >
> > * @summary Test proper scoping of @SuppressWarnings in the presence of
> > constant
> > variables
> > * @author
> > gafter
> >
> > *
> >
> > * @clean
> > SuppressScope
> >
> > * @compile -Xlint:divzero -Werror
> > SuppressScope2.java
> >
> > */
> >
> > class SuppressScope2 {
> > static class Y {
> > final static int i = X.K + 2;
> > }
> >
> > static class X {
> > @SuppressWarnings("divzero")
> > final static int K = 1 / 0;
> > }
> > }
> > *
> >
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.6 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
>
> iD8DBQFINeStmnpgrYe6r60RAsgUAKCJjwO6OXXGGOax7UDTDFTX9EVmBwCdFfYb
> io8NR7mbjf6isuyM/mjMN+0=
> =aZ7b
> -----END PGP SIGNATURE-----
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.openjdk.java.net/pipermail/closures-dev/attachments/20080522/920e24d8/attachment.html
More information about the closures-dev
mailing list