Only spying some of the time / using spypoint_condition
- From: "brianna.laugher@xxxxxxxxx" <brianna.laugher@xxxxxxxxx>
- Date: Mon, 20 Aug 2007 03:49:11 -0000
Hello,
I'm trying to debug a complex Prolog program and I have a spy set on a
particular predicate. However this predicate gets called a lot and
most of the times I'm not interested in it. So I only want to spy on
it when the arguments match what I'm interested in. It seems like
spypoint_condition is what I need to use.
(from http://www.sics.se/SICS-reports/SICS-T--93-01--SE/report_4.html
)
spypoint_condition(:Goal,?Port,+Test) Sets a conditional spy-point on
the predicate for Goal. When the debugger reaches the spy-point, three
conditions must be met for the spy-point to apply: The actual goal
must match Goal, the actual port must match Port, and Test (an
arbitrary Prolog goal) must succeed.
<<
I tried doing
spypoint_condition(predicate_name, _, _).
because I'm not sure how those other arguments should work, but it was
a waste of time because it's an unknown predicate anyway. :/ I'm using
MasterProlog.
Any thoughts on how to approach this?
thanks,
Brianna
.
- Prev by Date: comp.lang.prolog Frequently Asked Questions
- Next by Date: Which free Prolog is the best one ?
- Previous by thread: Broken example in Bratko?
- Next by thread: Which free Prolog is the best one ?
- Index(es):