Repository navigation
Conversation
|
forgot to commit the test. one sec. edit unfortunately this can't be easily end-to-end tested within this module since the test JVM doesn't have the javap module in it due to how it sets up nb-javac. It could be made testable by changing the impl to get javap via the default java platform and spawn a process, but the nice thing about the current impl is that it remains in-process. |
29b7520 to
756da86
Compare
|
One thing to note is that javap in newer versions of JDK - those that use the ClassFile API do not tolerate newer classfiles anymore. How much that is a problem, not sure. |
|
thanks for the heads up. I mostly checked the lower bound case (JDK 21 javap used on bytecode of 28). Will do a bit of testing using 25 on bytecode of 28. |
- temporary implementation until JDK 25 bump which unlocks public classfile API - uses javap of the runtime JDK (in process) if possible and a compatible JDK from the platform manager as fallback (extra process) fixes apache#9368
756da86 to
8fa3332
Compare
|
confirmed. javap of JDK 25+ only supports bytecode up to its own version, while JDK 21 is more tolerant. Thanks for pointing this out since I would have overlooked that. changed it into two code paths:
situation regarding future JDK 25 bump changes slightly too: the first path could be rewritten and the fallback kept (updated PR description) |
related: #8931
fixes #9368