mirror of
https://github.com/Mercury-Language/mercury.git
synced 2026-04-15 17:33:38 +00:00
trace/mercury_trace_spy.c:
When the user wants to put a breakpoint on a line in a file,
but there is no event exactly on the given line number,
mdb used to tell the user just that fact. This diff makes
mdb more helpful, by printing the nearest line numbers before
and after the given line number that *do* have events on which
breakpoints can be put.
The mismatch can come for several reasons, with the most common
probably being that textually, a switch arm for e.g X being f
starts with the X = f unification goal, but switch detection
*deletes* that unification from the switch arm, so the event
for entry into that arm is actually on the line for the *next* goal.
trace/mercury_trace_tables.[ch]:
Provide the info needed by mercury_trace_spy.c.
Change the interface of MR_process_file_line_layouts to make it
self-contained, i.e. returning counts of matches, instead of
merely *adding* to preexisting counts. This is simpler, since
the only caller of that function needs no running tally.
tests/debugger/breakpoints.inp:
Extend this test to test the possible error messages we now generate.
tests/debugger/breakpoints.exp:
tests/debugger/breakpoints.exp2:
Update the expected outputs in both debug and non-debug grades.
84 lines
1.4 KiB
Plaintext
84 lines
1.4 KiB
Plaintext
echo on
|
|
register --quiet
|
|
break data
|
|
*
|
|
delete 1
|
|
delete 0
|
|
break data
|
|
1
|
|
continue
|
|
disable 0
|
|
break info
|
|
break qperm
|
|
break safe
|
|
break -e qperm
|
|
break -a qperm
|
|
break /
|
|
0
|
|
break //2
|
|
0
|
|
break breakpoints.print_list.-/2
|
|
break breakpoints.print_list.--0
|
|
break breakpoints__print_list__/-0
|
|
break breakpoints__print_list__print_list
|
|
break breakpoints.print_list.print_list/3
|
|
break info
|
|
delete 0
|
|
break info
|
|
disable 3
|
|
break nodiag
|
|
break_print -v -n -b1 HeadVar__1 HeadVar__2
|
|
continue
|
|
break_print -b1 none
|
|
format_param -p depth 10
|
|
format_param -p size 20
|
|
break_print -p -n -b1 HeadVar__1 HeadVar__2
|
|
continue
|
|
finish -N
|
|
finish -n
|
|
break_print -b1 none
|
|
break_print -f -n -b1 HeadVar__1
|
|
break_print -f -e -n -b1 HeadVar__2
|
|
continue
|
|
continue
|
|
finish
|
|
delete *
|
|
break info
|
|
delete *
|
|
break -i -I3 qperm
|
|
continue
|
|
print *
|
|
ignore -E4 0
|
|
continue
|
|
print *
|
|
delete *
|
|
break -O test_in_both
|
|
break breakpoints.test_in_both
|
|
break breakpoints.print_list.test_in_both
|
|
delete *
|
|
break print_list.test_in_both
|
|
break print_list.test_only_in_printlist
|
|
delete *
|
|
break test_only_in_printlist
|
|
delete *
|
|
procedures testmod
|
|
procedures a
|
|
procedures a.testmod
|
|
break -O test_in_ab
|
|
break -O testmod.test_in_ab
|
|
break -O a.testmod.test_in_ab
|
|
break -O b.testmod.test_in_ab
|
|
delete *
|
|
break -O -p goal test_in_a
|
|
break -O -P -p HeadVar__1 test_in_b
|
|
break info
|
|
continue
|
|
break_print -b0 none
|
|
break_print -b0 *
|
|
break nonexistent.m:1000
|
|
break breakpoints.m:1000
|
|
break breakpoints.m:2
|
|
break breakpoints.m:82
|
|
continue
|
|
continue
|