This is the mail archive of the kawa@sourceware.cygnus.com mailing list for the Kawa project.


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

Re: cannot 'require' in embedded code (AGAIN...)


Marco Vezzoli <marco.vezzoli@st.com> writes:

> It seems that evalunating a "require" statement is the correct way, but
> I get this exception.
> 
> > Exception in thread "main" java.lang.Error: internal error - SetExp.eval
> > with lexical binding
> >  at gnu.expr.SetExp.eval(SetExp.java, Compiled Code)

I've been looking at this.  It is easy to fix the immediate problem;
just apply the fix below.  But that there are more fundamental
problems that are harder to solve - though I guess it is possible
you won't run into them or can work around them.

Index: require.java
===================================================================
RCS file: /cvs/kawa/kawa/kawa/standard/require.java,v
retrieving revision 1.3
diff -u -r1.3 require.java
--- require.java	2000/03/18 18:50:00	1.3
@@ -178,6 +179,7 @@
       }
     else
       forms.addElement(QuoteExp.voidExp);
+    tr.mustCompileHere();
     return true;
   }
-- 
	--Per Bothner
per@bothner.com   http://www.bothner.com/~per/

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