This is the mail archive of the
java-discuss@sourceware.cygnus.com
mailing list for the Java project.
Re: BigInteger compile fails
- To: Matt Welsh <mdw at cs dot berkeley dot edu>
- Subject: Re: BigInteger compile fails
- From: Warren Levy <warrenl at cygnus dot com>
- Date: Tue, 15 Feb 2000 15:33:35 -0800 (PST)
- cc: Tom Tromey <tromey at cygnus dot com>, java-discuss at sourceware dot cygnus dot com
On Mon, 14 Feb 2000, Matt Welsh wrote:
> > Either the latest egcs, or 2.95.2 with Bryce's compatibility patch.
>
> I was using Bryce's patch. There must be something else wrong with 2.95.2
> then?
There's an easy workaround in the BigInteger source code. If you can't find
the right compiler fix, go ahead and apply this in the meantime.
--warrenl
--- BigInteger.java Mon Feb 14 02:01:31 2000
+++ BigInteger.java.workaround Tue Feb 15 15:29:14 2000
@@ -279,7 +279,10 @@ public class BigInteger extends Number i
private final boolean isNegative()
{
- return (words == null ? ival : words[ival - 1]) < 0;
+ // FIXME: compiler error in egcs-19991214 when compiling to bytecode (only).
+ // return (words == null ? ival : words[ival - 1]) < 0;
+ int tmp = (words == null ? ival : words[ival - 1]);
+ return tmp < 0;
}
public int signum()