Debugging for javac - plugin detailAdds a new tab "Decompile" to each Java source file. This tab shows either the output of javap on classfile compiled from the code in the editor, or Java-like code representing "desugared" source code.
[ You have to be logged in to be able to comment. ] User CommentsException on Netbeans 8.2, test class is sun.security.pkcs12.MacData
SEVERE [org.openide.util.RequestProcessor]: Error in RequestProcessor org.netbeans.modules.java.debugjavac.DecompiledTab$1
java.lang.IllegalArgumentException: Not supported: org.netbeans.modules.java.debugjavac.impl.Utilities$1[mem://mem] at com.sun.tools.javac.file.JavacFileManager.isSameFile(JavacFileManager.java:708) at javax.tools.ForwardingJavaFileManager.isSameFile(ForwardingJavaFileManager.java:90) at com.sun.tools.javac.api.ClientCodeWrapper$WrappedJavaFileManager.isSameFile(ClientCodeWrapper.java:256) at com.sun.tools.javac.comp.Enter.visitTopLevel(Enter.java:354) at com.sun.tools.javac.tree.JCTree$JCCompilationUnit.accept(JCTree.java:511) at com.sun.tools.javac.comp.Enter.classEnter(Enter.java:300) at com.sun.tools.javac.comp.Enter.classEnter(Enter.java:315) at com.sun.tools.javac.comp.Enter.complete(Enter.java:721) at com.sun.tools.javac.comp.Enter.main(Enter.java:705) at com.sun.tools.javac.main.JavaCompiler.enterTrees(JavaCompiler.java:1008) at com.sun.tools.javac.processing.JavacProcessingEnvironment$Round.enterTrees(JavacProcessingEnvironment.java:1061) at com.sun.tools.javac.processing.JavacProcessingEnvironment$Round.(JavacProcessingEnvironment.java:956) at com.sun.tools.javac.processing.JavacProcessingEnvironment$Round.next(JavacProcessingEnvironment.java:974) at com.sun.tools.javac.processing.JavacProcessingEnvironment.doProcessing(JavacProcessingEnvironment.java:1168) at com.sun.tools.javac.main.JavaCompiler.processAnnotations(JavaCompiler.java:1210) at com.sun.tools.javac.main.JavaCompiler.compile(JavaCompiler.java:884) at com.sun.tools.javac.api.JavacTaskImpl$1.call(JavacTaskImpl.java:104) at com.sun.tools.javac.api.JavacTaskImpl$1.call(JavacTaskImpl.java:100) at com.sun.tools.javac.api.JavacTaskImpl.handleExceptions(JavacTaskImpl.java:139) Caused: java.lang.RuntimeException at com.sun.tools.javac.api.JavacTaskImpl.handleExceptions(JavacTaskImpl.java:155) at com.sun.tools.javac.api.JavacTaskImpl.doCall(JavacTaskImpl.java:100) at com.sun.tools.javac.api.JavacTaskImpl.call(JavacTaskImpl.java:94) at org.netbeans.modules.java.debugjavac.impl.JavapDecompilerImpl.compile(JavapDecompilerImpl.java:141) at org.netbeans.modules.java.debugjavac.impl.JavapDecompilerImpl.decompile(JavapDecompilerImpl.java:86) at org.netbeans.modules.java.debugjavac.CompilerDescription$Factory$LoaderBased.decompile(CompilerDescription.java:189) at org.netbeans.modules.java.debugjavac.DecompiledTab.doDecompileIntoDocument(DecompiledTab.java:187) at org.netbeans.modules.java.debugjavac.DecompiledTab.access$000(DecompiledTab.java:103) at org.netbeans.modules.java.debugjavac.DecompiledTab$1.run(DecompiledTab.java:161) at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1443) at org.netbeans.modules.openide.util.GlobalLookup.execute(GlobalLookup.java:68) at org.openide.util.lookup.Lookups.executeWith(Lookups.java:303) [catch] at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2058)
Posted by ggghhhjjj on Mar 26, 2018
Works for Netbeans 8.2!
It works for Netbeans 8.2! Great plugin! Thank you!
Posted by mgmechanics on Dec 06, 2017
Source code for this plugin
The source code for this plugin is available in directory java.debugjavac of the contrib repository:
http://hg.netbeans.org/main/contrib
Posted by jlahoda on Apr 28, 2014
Does exactly what's needed, very easily. Excellent!
I was looking for a way to simplify using javap with NB. It was surprisingly hard to find, but well worth the effort. Does exactly what I needed.
Thank you
Posted by jamescherrill on Apr 28, 2014
Very nice!
Awesome, exactly what I was looking for. Is this plugin open source?
Posted by sese1967 on Mar 28, 2014
JDK6 support
Sorry, but I don't plan to backport to JDK6. The plugin was originally written for 7.4, and I backported the dependencies to match 7.3, but going back to JDK6 prove to be too difficult to be effective (the code not only uses diamond operator, which can be alleviated relatively easily, but also switch over Strings, etc.). I made sure the plugin itself requires JDK7, so the error message should be understandable, but I don't have plans to do more to support JDK6.
Posted by jlahoda on Aug 15, 2013
can't install on JDK6
Hi,
I can't install this plugin on NetBeans running on JDK6. NetBeans 7.3 is designed to run on JDK6 and 7 (NetBeans Dailybuilds and 7.4 will run on JDK7 only, but we're still on Netbeans 7.3). Could you recompile your plugin for JDK6? Thx! The error message on plugin install: Some plugins require the Java platform in version Java > 1.7 The Java platform version Java > 1.7 was requested but only 1.6 is running. The following plugin is affected: Debugging for javac
Posted by ent38 on Aug 15, 2013
|