ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jason Rosenberg" <ja...@squaretrade.com>
Subject Re: Fw: Problem using script task
Date Thu, 28 Dec 2000 01:54:57 GMT
Nico,

would you mind telling me in plain language how I can get this
fix installed on my system?

I did download the bsf stuff and ran the build stuff for it.  Is it
just a matter of updating one of the source files for bsf, and
re-building bsf?

If so, could you post the new version of JavaScriptEngine.java
to this group too, so that we can use it right away, instead of
waiting for the bsf people to move on it?

I suppose I could try implementing the changes directly, too...

Jason

----- Original Message ----- 
From: "Nico Seessle" <Nico.Seessle@epost.de>
To: <ant-dev@jakarta.apache.org>
Sent: Wednesday, December 27, 2000 6:53 PM
Subject: Re: Fw: Problem using script task


> Hi,
> 
> the problem is not inside ant, it seems to be a problem with BSF if there
> are properties (in ant) handed over to BSF containing String's.
> 
> I just posted the following patch to bsf-discussion (and hope someone will
> commit it)
> 
> Index: JavaScriptEngine.java
> ===================================================================
> RCS file:
> /usr/cvs/bsf/bsf-src/src/com/ibm/bsf/engines/javascript/JavaScriptEngine.jav
> a,v
> retrieving revision 1.3
> diff -u -r1.3 JavaScriptEngine.java
> --- JavaScriptEngine.java 2000/11/14 15:28:20 1.3
> +++ JavaScriptEngine.java 2000/12/28 00:32:55
> @@ -58,14 +58,14 @@
>        global = cx.initStandardObjects (new ImporterTopLevel ());
>        Scriptable bsf = cx.toObject (new BSFFunctions (mgr, this), global);
>        global.put ("bsf", global, bsf);
> +
> +      int size = declaredBeans.size ();
> +      for (int i = 0; i < size; i++) {
> +        declareBean ((BSFDeclaredBean) declaredBeans.elementAt (i));
> +      }
>      } finally {
>        Context.exit();
>      }
> -
> -    int size = declaredBeans.size ();
> -    for (int i = 0; i < size; i++) {
> -      declareBean ((BSFDeclaredBean) declaredBeans.elementAt (i));
> -    }
>    }
> 
>    /**
> 
> This was a change introduced in revision 1.3, so if you want to build bsf
> you need to explicitely get rev 1.2 of the file.
> 
> The sample works for me with this patch.
> 
> Bad testing there :-)
> 
> Nico
> 
> ----- Original Message -----
> From: "Marco Struck" <M.Struck@PopNet.de>
> To: <ant-dev@jakarta.apache.org>
> Sent: Wednesday, December 27, 2000 11:41 AM
> Subject: AW: Fw: Problem using script task
> 
> 
> Hi Jason, you are not alone. I've gone the same way like you and failed at
> the same
> exception. The script task is the last hope for some logical rulings in
> Ant1.2, but
> unfortunately it doesn't work. Nobody knows why.
> 
> Perhaps there is one of the programmers of the script task ... I think it's
> easier for
> one of them to solve that problem.
> 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ant-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: ant-dev-help@jakarta.apache.org
> 


Mime
View raw message