Re: [RFA] gdb.mi/mi2-var-display.exp: fullname field testing

Nick Roberts
2007-04-09T10:10:11Z

> # The running part has been checked already by mi_run_cmd
> gdb_expect {
> - -re "\[\r\n\]*000\\*stopped,reason=\"breakpoint-hit\",bkptno=\"1\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"do_children_tests\",args=\\\[\\\],file=\".*var-cmd.c\",line=\"$line_dct_end\"\}\r\n$mi_gdb_prompt$" {
> + -re "\[\r\n\]*000\\*stopped,reason=\"breakpoint-hit\",bkptno=\"1\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"do_children_tests\",args=\\\[\\\],file=\".*var-cmd.c\",fullname=\"${fullname_syntax}${srcfile}\",line=\"$line_dct_end\"\}\r\n$mi_gdb_prompt$" {
> pass "run to do_children_tests"

I guess this didn't fail before because .* is greedy, and therefore matched up
to the second var-cmd.c in the fullname field. It would be nice to use
non-greedy expressions, normally .*?, but this don't seem to work with
Dejagnu.

--
Nick http://www.inet.net.nz/~nickrob