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.
NetBeans IDE 4.2 [200504181800] on jdk 1.5.0_03 1, Open som eclass with main method 2, Create method breakpoint on constructor of the class 3, Start debugging the class => the breakpoint is not reached This same scenario worked in NB4.0
I do not understand this. The main method is static, right? Then why would anyone touch the constructor? IMHO this behavior is correct. Please elaborate...
Investigation of problem showed, this behaviour is same for all constructors. Probably this is correct, because such a method breakpoint cannot be created also in jdb. But as I wrote - this was possible and worked fine in NB 4.0. If the behaviour of NB 4.0 was wrong, we are now missing a feature which worked. A workaroud to create breakpoint for method name <init> is usable, but not easily findable for less advenced users. This must be solved, otherwise such users will be confused why the breakpoint did not work.
This does not seem to be a P3 priority - it has an easy workaround - set breakpoint for <init> method.
Unfortunately this workaround is not easily findable for less advanced users. It would be nice if debugger compares method name to class name and in case it finds them same, set the breakpoint on method <init>. I tested the <init> method breakpoints and they work nice even for inner classes (with inner classes you have to compare only last part of class name, they are separated by $ character). I think this is doable ;-)
Created attachment 23079 [details] Attaching test class for later testing of <init> method breakpoints
Should work fine after issue #75233 was fixed.
Verified ... and Closing all issues resolved into NetBeans 6.7 and earlier.