This is the mail archive of the
mailing list for the GDB project.
Re: How do I get regexp from expect at gdb_expect?
On Mon, Jan 31, 2005 at 05:03:54PM -0500, Daniel Jacobowitz wrote:
> On Mon, Jan 31, 2005 at 05:00:50PM -0500, Bob Rossi wrote:
> > It also tighten's up the MI output command matching, I honestly don't
> > know how the -break-delete was getting eaten in the regular expression,
> > unless $pattern happened to have a .*. Oops, in that case, I guess we
> > aren't really validation much, anything could have come out of GDB, and
> > it probably would have passed.
> Your pattern doesn't start with an anchor. -break-delete wasn't eaten;
> we just started matching after it.
Please forgive my ignorance, I've been reading online as much as
possible to understand tcl/expect ...
I understand how anchors work, however, I didn't realize you could start
matching in the middle of what the 'buffer' is. If it started matching
after it, does that mean it's skipped forever? So basically, you can
match a subset of the output, and the rest is lost (never matched)?
If that's the case, the testsuite for the MI is matching even less than
I thought. GDB could output almost anything, but then just have to match
the last string, and the testcase would pass, correct?