How do I get regexp from expect at gdb_expect?
Bob Rossi
bob@brasko.net
Sat Jan 29 02:57:00 GMT 2005
Hi,
I'm using expect with GDB and I've come across a problem. For instance,
say I have,
gdb_expect $tmt {
-re "(Ending remote debugging.*$mi_gdb_prompt\[ \]*$)" {
# at this point, how do I get the string that matched the above
# regex?
}
}
}
I need to be able to get the string that matched the regex at the -re.
If I can get this data, I think I will successfully be able to get the
MI output parser to parse the output of GDB with the existing testsuite.
This will at least ensure that the syntax is correct, and will stay
correct.
I hope it is possible to get the information that I need ...
Any help would be greatly appreciated,
Thanks,
Bob Rossi
More information about the Gdb
mailing list