Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

upgrade ASM #21

Open
GoogleCodeExporter opened this issue Sep 9, 2015 · 6 comments
Open

upgrade ASM #21

GoogleCodeExporter opened this issue Sep 9, 2015 · 6 comments

Comments

@GoogleCodeExporter
Copy link

BeanShell uses an ancient version of ASM.  See:

http://asm.objectweb.org/

This needs to be upgraded to fix a number of bugs and to add new java features.

Original issue reported on code.google.com by fschm...@gmail.com on 29 Mar 2008 at 8:27

@GoogleCodeExporter
Copy link
Author

FYI, if you don't know it, Maven2 has maven-shade-plugin "to package the 
artifact in
an uber-jar, including its dependencies and to shade - i.e. rename - the 
packages of
some of the dependencies".
see http://maven.apache.org/plugins/maven-shade-plugin/

It seems like this one would be useful to upgrade asm without hassle.

If you're interested but either don't know maven-shade-plugin, or even Maven2, 
just
tell me and I can help.

Original comment by herve.bo...@free.fr on 26 Dec 2008 at 11:37

@GoogleCodeExporter
Copy link
Author

I took a quick look at this, and it looks like org.objectweb.asm.ClassWriter no
longer exists in asm.  It seems like the easiest route would be to extract the
interface of ClassWriter that bsh uses, and re-implement that with the current 
asm
APIs, and update the classes as needed.  This may not be the best way to go 
about it
though, since I don't really know how ClassWriter is used in bsh, and I'm not 
100%
convinced that that is the only asm class in use currently.

Original comment by cresw...@gmail.com on 12 Feb 2009 at 6:47

@GoogleCodeExporter
Copy link
Author

This is not the case. The issue is that BeanShell renames the package to 
bsh.org.objectweb.asm, which makes every thing break. There are also API 
changes in the 
new ASM package, for which BeanShell source needs fix. I figured this out for 
another 
project I am doing for which I needed to add some features to BeanShell. Have a 
look at 
the my modified source repo at: 
http://code.google.com/p/metastudio/source/browse/trunk/metastudio/lib/src/bsh/s
rc/bsh/


Original comment by tovganesh@gmail.com on 16 Sep 2009 at 4:10

@GoogleCodeExporter
Copy link
Author

@tovganesh  You have a bunch of files in that linked-to directory. Can you pls 
enumerate which of those you actually made changes to?

thx

Original comment by javadba@gmail.com on 29 May 2011 at 10:19

@GoogleCodeExporter
Copy link
Author

While we're at it, why not abstract out the class writer so that it can use 
assemblers for different VMs?  For instance, I plan to use smali's dexlib to 
generate Dalvik classes... if we could make a pluggable interface that uses 
ASM, dexlib, or whatever, then that would expand the scope of beanshell2's 
usability.

Original comment by DPWhitta...@gmail.com on 4 Aug 2011 at 4:10

@GoogleCodeExporter
Copy link
Author

I know this is an old issue, but it was actually quite trivial by version 
stepping to get beanshell to work with asm 4.1/5.0-alpha.  just removed the 
embedded asm package and linked in the jar progressing though each version 
until it was current and fixing errors as I went.  the only file that needed 
modified was ClassGeneratorUtil.java which is attahed.

-Allen

Original comment by allenso...@gmail.com on 11 Apr 2013 at 4:33

Attachments:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant