This is the mail archive of the
kawa@sources.redhat.com
mailing list for the Kawa project.
Re: Using 'eval' wrongly?
- To: Jocelyn Paine <popx at pop3 dot ifs dot org dot uk>
- Subject: Re: Using 'eval' wrongly?
- From: Per Bothner <per at bothner dot com>
- Date: Mon, 27 Aug 2001 13:26:30 -0700
- CC: kawa at sourceware dot cygnus dot com
- References: <Pine.LNX.4.10.10108272019470.4710-100000@pop3.ifs.org.uk>
Jocelyn Paine wrote:
> I'm testing that I can construct expressions and evaluate them from Java.
> There's some code below which I think ought to call eval to evaluate (- 1
> 2), and return -1. What it actually seems to return is an empty Values,
> presumably representing #!void.
I just got private email about the same problem. Please try the
attached patch.
Index: ModuleExp.java
===================================================================
RCS file: /cvs/kawa/kawa/gnu/expr/ModuleExp.java,v
retrieving revision 1.20
diff -u -r1.20 ModuleExp.java
--- ModuleExp.java 2001/08/18 01:31:11 1.20
+++ ModuleExp.java 2001/08/27 19:01:24
@@ -180,8 +180,8 @@
ModuleBody mod = (ModuleBody) eval (env);
gnu.kawa.reflect.ClassMemberConstraint.defineAll(mod, env);
ctx.proc = mod;
- ctx.run();
}
+ ctx.run();
}
finally
{