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.

Bug 58046 - Method breakpoint on constructor is not reached
Summary: Method breakpoint on constructor is not reached
Status: CLOSED FIXED
Alias: None
Product: debugger
Classification: Unclassified
Component: Java (show other bugs)
Version: 5.x
Hardware: PC Linux
: P4 blocker (vote)
Assignee: issues@debugger
URL:
Keywords: USABILITY
Depends on:
Blocks:
 
Reported: 2005-04-19 15:48 UTC by _ lcincura
Modified: 2010-04-29 09:22 UTC (History)
0 users

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments
Attaching test class for later testing of <init> method breakpoints (1.55 KB, text/plain)
2005-07-13 11:41 UTC, _ lcincura
Details

Note You need to log in before you can comment on or make changes to this bug.
Description _ lcincura 2005-04-19 15:48:51 UTC
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
Comment 1 Martin Entlicher 2005-05-16 17:16:20 UTC
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...
Comment 2 _ lcincura 2005-05-24 13:19:39 UTC
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.
Comment 3 Martin Entlicher 2005-07-13 11:13:52 UTC
This does not seem to be a P3 priority - it has an easy workaround - set
breakpoint for <init> method.
Comment 4 _ lcincura 2005-07-13 11:39:58 UTC
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 ;-)
Comment 5 _ lcincura 2005-07-13 11:41:21 UTC
Created attachment 23079 [details]
Attaching test class for later testing of <init> method breakpoints
Comment 6 Martin Entlicher 2007-05-23 10:22:27 UTC
Should work fine after issue #75233 was fixed.
Comment 7 Quality Engineering 2010-04-29 09:22:13 UTC
Verified ... and Closing all issues resolved into NetBeans 6.7 and earlier.