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.
Support autos view in variables (as in cnd)
UI part in: http://lessing.sfbay.sun.com/hg/toolshg/rev/6ab530a104e3
PARTFIX http://lessing.sfbay.sun.com/hg/toolshg/rev/02262f85b4ad Prep work: - Added public NativeDebugger.visitedLocation(). This allows us to know the current src file and line #. It used to be a protected method called visit_loc(). - Added EditorBridge.documentFor() to convert file pathnames to Documents. - Adedd infrastructure to track, in a NativeDebugger, when showAutos is turned on and off: o NatievDebuggerIMpl.setAustos()/isAutos(). o Register ActionListener in LocalModel constructor o Call setAutos() in LocalModel.add/removeModelListener(). The following only done for dbx ... First attempt: Enhanced Egors LocalModel.getAutos() to filter list of local Variables with the Set returned by Autos. But this doesn't handle globals, member variables and more complex expressions. Second attempt: DbxDebuggerImpl.requestAutos() iterates through the list provided by Autos and sends individual expression evaluation requests to dbx. When the last response arrives we trigger a pull of locals which retrieves autos via NativeDebugger.getAutos(). This allows for a more accurate LocalModel.getChildrenCount(). I first triggerred requestAutos() in setLocals() but unfortunately visitedLocation gets set _after_ setLocals(). Currently requestAutos gets triggerred in DbxDebuggerImpl.makeCurrent(). This works reasonably well with frame and stack switches. However we still have some issues: - Pointer chasing is (sometimes) inoperative. Even after getting it to work remembering which variabels were chased will be tricky as teh set of chased pointers will arrive before the answers to requestAutos(). Given that Autos sometimes returns fields (e.g. p.f1) we could disable pointer chasing for autos. - switching showAutos's on and off doesn't always refresh the view. - When in disassembly autos don't get cleared. - view not cleared on proc_gone ... possibly other state transitions. - The mgmt for NativeDebugger auto state needs a bit of work still. It requires the view button to be on _and_ locals to be displayed.
Thanks a lot! I've fixed difference in line numbering with: http://lessing.sfbay.sun.com/hg/toolshg/rev/a5dc8ccc62e9 Noticed an issue: - locals are not set if in autos mode (there is a check for that in setLocals), because of that switch back to locals mode shows empty list of locals
http://lessing.sfbay.sun.com/hg/toolshg/rev/a2642342b6d5 Dealt with leftover issues ... - Pointer chasing works for autos. But there's no memory from step to step. The reason for this is that dbx pushes the vaues of remembered opened nodes before we have the opportunity to handle the autos for the current line. - Autos gets cleared properly when debuggee is killed or we switch to a frame with only assembly level information. - Commented out debugging printfs. - Renamed NativeDebugger autos property to showAutos so it's not confused with actual 'autos' list.