This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
1. Create the following class in the default package public class TstDebug { int ivar = 1; float fvar = 3.14f; /** Creates new TstDebug */ public TstDebug() { String local1 = "Local1"; Integer local2 = new Integer(ivar); Object local3 = this; } public static void main(String[] args) { TstDebug tst = new TstDebug(); } } 2. View the classes properties and set the Compiler value to FastJavac. Inspect the FastJavac compiler settings to see theat Debug is True and Optimize is False. 3. Compile the TstDebug class. 4. Dump out the class local variable table using javap and you will see there is no debugging info: bash-2.04$ javap -l TstDebug Compiled from TstDebug.java public class TstDebug extends java.lang.Object { int ivar; float fvar; public TstDebug(); public static void main(java.lang.String[]); } Line numbers for method TstDebug() line 8: 0 line 4: 4 line 5: 9 line 10: 15 line 11: 18 line 12: 30 line 8: 32 Line numbers for method void main(java.lang.String[] line 17: 0 line 15: 8 bash-2.04$ 5. Change the Compiler to Internal and then compile the class. Dumping out the local variable table now shows debugging info: bash-2.04$ javap -l TstDebug Compiled from TstDebug.java public class TstDebug extends java.lang.Object { int ivar; float fvar; public TstDebug(); public static void main(java.lang.String[]); } Line numbers for method TstDebug() line 9: 0 line 4: 4 line 5: 9 line 10: 15 line 11: 18 line 12: 30 line 13: 32 Local variables for method TstDebug() TstDebug this pc=0, length=33, slot=0 java.lang.String local1 pc=18, length=14, slot=1 java.lang.Integer local2 pc=30, length=2, slot=2 java.lang.Object local3 pc=32, length=0, slot=3 Line numbers for method void main(java.lang.String[]) line 17: 0 line 18: 8 Local variables for method void main(java.lang.String[]) java.lang.String[] args pc=0, length=9, slot=0 TstDebug tst pc=8, length=0, slot=1 bash-2.04$ Forte4j version info: ------------------------------------------------------------------------------- >Log Session: Friday, September 22, 2000 8:51:01 AM PDT >System Info: Product Version = NetBeans IDE, Development Version (Build 35) IDE Versioning = IDE/1 spec=1.1.1 impl=Build 35 Operating System = Windows 2000 Version 5.0 Running on x86 Java Version = 1.3.0 Java VM Version = Java HotSpot(TM) Client VM 1.3.0-C Java Vendor = Sun Microsystems Inc. Java Vendor URL = http://java.sun.com/ Java Home = D:\usr\local\Java\jdk1.3\jre Java Class Version = 47.0 System Locale = en_US JIT = unknown or not used Home Dir = D:\Documents and Settings\Administrator Current Directory = D:\usr\local\Java\Forte4j_devl\netbeans\bin IDE Home = .. IDE User Home = .. System Directory = ..\system CLASSPATH = ..\lib;..\lib\openide.jar;..\lib\developer.jar;..\lib\ext\AbsoluteLayout.jar;. .\lib\ext\javac.jar;..\lib\ext\jaxp.jar;..\lib\ext\jh.jar;..\lib\ext\nb- editor.jar;..\lib\ext\openidex.jar;..\lib\ext\parser.jar;..\lib\ext\regexp.jar;. .\lib\ext\servlet.jar;/usr/local/Java/jdk1.3\lib\dt.jar;/usr/local/Java/jdk1.3 \lib\tools.jar;D:\usr\IBMVJava2 \eab\runtime30;\usr\local\src\scott_home_rips\packages;.\ASEP\Monclass.zip;.\ASE P\3pclass.zip ------------------------------------------------------------------------------- [INFO] Loaded modules: org.netbeans.modules.clazz/1 (1.3/35); org.netbeans.modules.html/1 (1.3/35); org.netbeans.modules.httpserver/1 (1.3/35); org.netbeans.modules.icebrowser/1 (1.3/35); org.netbeans.modules.image/1 (1.3/35); org.netbeans.modules.properties/1 (1.3/35); org.netbeans.modules.text/1 (1.3/35); org.netbeans.modules.usersguide/1 (1.3/35); org.openidex.util/1 (1.3/35); org.netbeans.modules.autoupdate/1 (1.3/35); org.netbeans.modules.debugger.core/1 (1.1.5/35); org.netbeans.modules.applet/1 (1.3/35); org.netbeans.modules.debugger.debug/1 (1.5/35); org.netbeans.modules.debugger.jpda/1 (1.5/35); org.netbeans.modules.editor/1 (1.4/35); org.netbeans.modules.jarpackager/1 (1.3/35); org.netbeans.modules.java/1 (1.3/35); org.netbeans.modules.beans/1 (1.3/35); org.netbeans.modules.form/1 (1.3/35); org.netbeans.modules.i18n/1 (1.3/35); org.netbeans.modules.javadoc/1 (1.3/35); org.netbeans.modules.objectbrowser/1 (1.3/35); org.netbeans.modules.projects/1 (1.3/35); org.netbeans.modules.utilities/1 (1.3/35); org.netbeans.modules.vcs.cmdline/1 (1.4/35); org.netbeans.modules.web.core/1 (1.1.3/35); org.netbeans.modules.web.wizard/1 (1.1.3/35) path="" :jsp: init
Please verify that the commandline (shown in FastJavac compilertype's property "External compiler") contains the replacement tag {debug}. It should, by default.
No {debug} is not there. This is the command line that exists: -jdk {java.home}{/}.. -classpath {filesystems}{:}{classpath}{:}{library}{:} {bootclasspath} {files} If I try to add {debug} or {Debug} in there before -classpath I get the error: fastjavac: Java source files must have a .java suffix: {Debug} 1 error
I was writing the message in a hurry before leaving for the weekend; thanks for providing a complete commandline ;-) The replacement tag is {debuginfo}, actually but it's still not in your commandline. I've installed a fresh dev-35 into a clean directory and this is the default FastJavac's commandline: {ide.home}{/}bin{/}fastjavac{/}fastjavac {debuginfo} {deprecation} {optimize} -jdk {java.home}{/}.. -classpath {filesystems}{:}{classpath}{:}{library}{:}{bootclasspath} {files} {debuginfo} is replaced by -g (or whatever you configure on the Expert property tab) or an empty string if you disable debug info. It seems that you had some (changed, corrupted or whatever) project settings: if so, then remove the compilation service and re-add it (or create a new FastJavac compiler type). The IDE should recreate the default commandline for you.
The project I was working with was one that had been imported from CE 1.0.1 version of forte and the import process did report problems with importing the project settings. If I look at the default project I do see the missing command options: {debuginfo} {deprecation} {optimize} -jdk {java.home}{/}.. -classpath {filesystems}{:}{classpath}{:}{library}{:}{bootclasspath} {files}
[I'm missing a state slightly less ugly than INVALID] So it seems that it's not really a bug; to avoid loss of all settings, you can a) recreate the FastJavac compiler type (remove & re-add) in your project b) modify the command line so it includes all the options you are planning to use (like the default one does). You may experience the same problem with External compiler type, the code differs only marginally from FastJavac; the same workaround is possible. Internal compiler does not construct a commandline so the options are directly propagated to the compiler's engine.
Resolved for 3.3.x or earlier, no new info since then -> closing.
Resolved for 3.4.x or earlier, no new info since then -> closing.