strange ClassFormatError with indy
Charles Oliver Nutter
headius at headius.com
Thu Aug 30 10:35:30 PDT 2012
On Thu, Aug 30, 2012 at 12:28 PM, Jochen Theodorou <blackdrag at gmx.org> wrote:
> To me it did read like Remi says the name is wrong. I was wondering if
> it is related to void as well...
That was my first thought too.
> Maybe it is better to give the method name as explicit argument and use
> the bytecode name for something else instead. Only... the bytecode
> started to read well again just now... But I guess I have to do that
> step, since Groovy allows in theory method names, that are not legal in
> bytecode.
I am using John Rose's algorithm for encoding "invalid" method names,
and it has worked great for us. We use them also for the actual name
of the method, which means they can show up a bit unusual in stack
traces, but otherwise the encoding is very simple to use.
Here's the logic in JRuby for encoding and decoding, based on John's logic:
https://github.com/jruby/jruby/blob/master/src/org/jruby/util/JavaNameMangler.java#L192
- Charlie
More information about the mlvm-dev
mailing list