Re: [bug?] Dynamically defined classes cause linkage errors (duplicate definitions).

Pat <[email protected]>
Newsgroups gmane.comp.java.beanshell.devel
Message-ID <[email protected]>
On Fri, Apr 23, 2004 at 05:18:58PM +0200, Dawid Weiss wrote:
> 
> which  defines  a  new  'scripted'  class  works  fine the first time it is
> executed. But successive attempts to run it throw:
> 
> java.lang.LinkageError: duplicate class definition: MyFactory

I'm afraid this is just a limitation of the beta release.  It was a quick hack
toget it working that obviously needs to be fixed.  We either need to use the
BeanShell classloader as a context classloader or at least use a naming
convention under the covers to partition our generated classes in the parent
classloader...

We might even want to have some options for how this works to accomodate
different kinds of environments...


Pat


-------------------------------------------------------
This SF.net email is sponsored by: The Robotic Monkeys at ThinkGeek
For a limited time only, get FREE Ground shipping on all orders of $35
or more. Hurry up and shop folks, this offer expires April 30th!
http://www.thinkgeek.com/freeshipping/?cpg=12297
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.