Open GraxCode opened 7 years ago
here the bytecode in krakatau assembly: https://hastebin.com/ququvibuto.cs
Is there an actual bug here, or is this just a request for lambda support? Because that sadly isn't going to happen in the forseeable future.
this is a request for lambda support, but why isn't this going to happen?
Because I don't have much time to work on Krakatau, and it would be a ton of work, and there's a lot of other higher priority things that need to be done and it's not clear how lambdas could be supported anyway.
it wouldn't be a ton of lines, it is actually quite easy.
If you think it is easy, you're welcome to try to implement it yourself.
https://ci.appveyor.com/api/buildjobs/gtyiueue5u7joyiv/artifacts/compiler%2Fjvm%2Ftarget%2Fwindows%2Fkaitai-struct-compiler.msi (unpack it for example with lessmsi, contains a bunch of jars inside)
io\kaitai\struct\formats\JavaClassSpecs$.java
cfr:
Log$.MODULE$.importOps().info((Function0<String> & java.io.Serializable & Serializable)() -> new StringContext(Predef$.MODULE$.wrapRefArray((Object[])new String[] {".... cached"})).s(Nil$.MODULE$));
krakatau:
io.kaitai.struct.Log$.MODULE$.importOps().info(/*invokedynamic*/null);
What are you trying to say?
These are just examples of incorrect decompilation. I have planned to create a new issje but found an already existing one, so just dumped its text here.
new Thread(/*invokedynamic*/null).start();
Here is the bytecode of an example method: https://hastebin.com/mucecemodi.cs
Starting this with verification works.
Its actually quite easy to handle lambdas. instead of null, there is %objref% -> { //parsed lambda method } %objref% is "()", when the innerdesc of the lambda-method is empty, else its just the localvariables parsed from the desc.