-
- VIP Member
- Posts: 147
- Joined: 5 Dec 2012 7:29
Breakpoint properties and conditions
Hi,
I was looking for a way of specifying a condition for stopping at a breakpoint when I opened its properties. I found 2 fields: comment and action.
The comment is the text that appears when you hover over the breakpoint marker; has anybody found this to be useful?
What about action? What is it intended for? What do I type in there?
Is it possible to specify a break condition at all?
I was looking for a way of specifying a condition for stopping at a breakpoint when I opened its properties. I found 2 fields: comment and action.
The comment is the text that appears when you hover over the breakpoint marker; has anybody found this to be useful?
What about action? What is it intended for? What do I type in there?
Is it possible to specify a break condition at all?
- Attachments
-
- break_properties.png (8.44 KiB) Viewed 19033 times
Mutall Data Management Technical Support
- Thomas Linder Puls
- VIP Member
- Posts: 1424
- Joined: 28 Feb 2000 0:01
- Ferenc Nagy
- VIP Member
- Posts: 215
- Joined: 24 Apr 2007 12:26
- Thomas Linder Puls
- VIP Member
- Posts: 1424
- Joined: 28 Feb 2000 0:01
Re:
Yes, but it is unsupported.Ferenc Nagy wrote:Does it work at all?
Yes.Ferenc Nagy wrote:Is it really non-documented?
Regards Thomas Linder Puls
PDC
PDC
-
- VIP Member
- Posts: 147
- Joined: 5 Dec 2012 7:29
Thomas,
The first attachment shows a point in the code where I want to break and observe certain variables under some condition. The problem is that very often I have to Debug Run very many times before I get to the condition of interest (and that is tiresome). I solve this by doing what is illustrated in the 2nd attachment: adding an if statement and breaking on the desired condition. This happens so often (and sometimes I forget to remove the extra code after debugging) that I wish conditional breaking was supported. Is there an alternative to my approach? Is it likely that future versions of Prolog will support conditional breakpoints?
The first attachment shows a point in the code where I want to break and observe certain variables under some condition. The problem is that very often I have to Debug Run very many times before I get to the condition of interest (and that is tiresome). I solve this by doing what is illustrated in the 2nd attachment: adding an if statement and breaking on the desired condition. This happens so often (and sometimes I forget to remove the extra code after debugging) that I wish conditional breaking was supported. Is there an alternative to my approach? Is it likely that future versions of Prolog will support conditional breakpoints?
- Attachments
-
- break.png (155.08 KiB) Viewed 18962 times
-
- break2.png (125.29 KiB) Viewed 18962 times
Mutall Data Management Technical Support
- Thomas Linder Puls
- VIP Member
- Posts: 1424
- Joined: 28 Feb 2000 0:01
-
- VIP Member
- Posts: 147
- Joined: 5 Dec 2012 7:29
-
- VIP Member
- Posts: 452
- Joined: 5 Nov 2000 0:01
-
- VIP Member
- Posts: 147
- Joined: 5 Dec 2012 7:29
Thank you Harrison.
When I got this response from Thomas, I searched this forum for further tips on debugging. I found 2 that I think are very useful.
The first one was Run in Window which allows me to see outputs without having to always include a readchar()=_ as in this sample:-
The second one was a way of navigating the code while not running it (in a way I was not aware of): Go to Position on Clipboard.. Thomas has a video that explains it very well.
When I got this response from Thomas, I searched this forum for further tips on debugging. I found 2 that I think are very useful.
The first one was Run in Window which allows me to see outputs without having to always include a readchar()=_ as in this sample:-
Code: Select all
run() :-
X= array2M{integer}::newAtomic(2,2),
I = X:get(0,0),
stdio::write(I).,
stdio::readChar()=_.
Mutall Data Management Technical Support
- Thomas Linder Puls
- VIP Member
- Posts: 1424
- Joined: 28 Feb 2000 0:01
The mentioned video is on youtube: Dump Demo - Visual Prolog 7.3 - IDE demonstration.
Regards Thomas Linder Puls
PDC
PDC