This is the mail archive of the
kawa@sources.redhat.com
mailing list for the Kawa project.
Re: define-constant: incorrect compilation
- From: Per Bothner <per at bothner dot com>
- To: wowa1 at online dot ru
- Cc: kawa at sources dot redhat dot com
- Date: Sat, 29 Mar 2003 13:27:03 -0800
- Subject: Re: define-constant: incorrect compilation
- References: <3E85E3EC.9070204@online.ru>
Hm. Looks like a bug from 2000 ...
I checked in the attached patch.
(I will try to look at your otherbug reports and patches soon, but
I'll be off-line at least until Monday.)
--
--Per Bothner
per at bothner dot com http://per.bothner.com/
Index: BindingInitializer.java
===================================================================
RCS file: /cvs/kawa/kawa/gnu/expr/BindingInitializer.java,v
retrieving revision 1.7
diff -u -r1.7 BindingInitializer.java
--- BindingInitializer.java 28 Oct 2002 21:47:52 -0000 1.7
+++ BindingInitializer.java 29 Mar 2003 21:21:22 -0000
@@ -25,11 +25,12 @@
if (value instanceof QuoteExp)
{
Object val = ((QuoteExp) value).getValue();
- if (val == null || val instanceof String)
- return;
- Literal lit = comp.litTable.findLiteral(val);
- if (lit.field == this.field)
- return;
+ if (val != null && ! (val instanceof String))
+ {
+ Literal lit = comp.litTable.findLiteral(val);
+ if (lit.field == this.field)
+ return;
+ }
}
if (! field.getStaticFlag())