This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: RFA: asm-source.exp: anchor regexp matching entry point symbol name
- From: Michael Snyder <msnyder at cygnus dot com>
- To: Jim Blandy <jimb at cygnus dot com>
- Cc: gdb-patches at sources dot redhat dot com
- Date: Mon, 10 Dec 2001 10:10:31 -0800
- Subject: Re: RFA: asm-source.exp: anchor regexp matching entry point symbol name
- Organization: Red Hat, Inc.
- References: <20011208195134.08A7F5E9D8@zwingli.cygnus.com>
Jim Blandy wrote:
>
> 2001-12-08 Jim Blandy <jimb@redhat.com>
>
> * gdb.asm/asm-source.exp (info symbol): Anchor the pattern
> matching the entry point symbol's name at the beginning of the
> line.
Thanks -- that's what I meant to do.
Please check it in.
>
> Index: gdb/testsuite/gdb.asm/asm-source.exp
> ===================================================================
> RCS file: /cvs/src/src/gdb/testsuite/gdb.asm/asm-source.exp,v
> retrieving revision 1.12
> diff -c -r1.12 asm-source.exp
> *** gdb/testsuite/gdb.asm/asm-source.exp 2001/12/07 02:50:02 1.12
> --- gdb/testsuite/gdb.asm/asm-source.exp 2001/12/08 19:49:07
> ***************
> *** 122,128 ****
> -re "info symbol 0x$entry_point\[\r\n\]*" {
> exp_continue
> }
> ! -re "(.*) in section .*$gdb_prompt $" {
> set entry_symbol $expect_out(1,string)
> pass "info symbol"
> }
> --- 122,131 ----
> -re "info symbol 0x$entry_point\[\r\n\]*" {
> exp_continue
> }
> ! -re "^(.*) in section .*$gdb_prompt $" {
> ! # It's important to anchor the pattern above at the beginning
> ! # of the line. Without that carat, the (.*) may end up
> ! # matching the empty string.
> set entry_symbol $expect_out(1,string)
> pass "info symbol"
> }