Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Jim Blandy <jimb@redhat.com>
To: gdb-patches@sources.redhat.com
Subject: RFA: make `info source' say whether macro info is present
Date: Wed, 22 May 2002 14:28:00 -0000	[thread overview]
Message-ID: <20020522201700.952B45EA11@zwingli.cygnus.com> (raw)


This will make it a bit easier to write tests that exit gracefully
when the test executable doesn't have any information about
preprocessor macros.  Alternative suggestions welcome.

gdb/ChangeLog:
2002-05-22  Jim Blandy  <jimb@redhat.com>

	* source.c (source_info): Mention whether the symtab has
	information about preprocessor macros.

gdb/testsuite/ChangeLog:
2002-05-22  Jim Blandy  <jimb@redhat.com>

	* lib/gdb.exp (get_debug_format): Tolerate message saying whether
	preprocessor macro information is present.

Index: gdb/source.c
===================================================================
RCS file: /cvs/src/src/gdb/source.c,v
retrieving revision 1.28
diff -c -r1.28 source.c
*** gdb/source.c	23 Apr 2002 11:09:09 -0000	1.28
--- gdb/source.c	22 May 2002 20:13:14 -0000
***************
*** 500,505 ****
--- 500,507 ----
  
    printf_filtered ("Source language is %s.\n", language_str (s->language));
    printf_filtered ("Compiled with %s debugging format.\n", s->debugformat);
+   printf_filtered ("%s preprocessor macro info.\n",
+                    s->macro_table ? "Includes" : "Does not include");
  }
  \f
  
Index: gdb/testsuite/lib/gdb.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/lib/gdb.exp,v
retrieving revision 1.18
diff -c -r1.18 gdb.exp
*** gdb/testsuite/lib/gdb.exp	10 May 2002 18:38:09 -0000	1.18
--- gdb/testsuite/lib/gdb.exp	22 May 2002 20:13:14 -0000
***************
*** 1435,1441 ****
      set debug_format "unknown"
      send_gdb "info source\n"
      gdb_expect 10 {
! 	-re "Compiled with (.*) debugging format.\r\n$gdb_prompt $" {
  	    set debug_format $expect_out(1,string)
  	    verbose "debug format is $debug_format"
  	    return 1;
--- 1435,1441 ----
      set debug_format "unknown"
      send_gdb "info source\n"
      gdb_expect 10 {
! 	-re "Compiled with (.*) debugging format.\r\n.*$gdb_prompt $" {
  	    set debug_format $expect_out(1,string)
  	    verbose "debug format is $debug_format"
  	    return 1;


             reply	other threads:[~2002-05-22 20:17 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-05-22 14:28 Jim Blandy [this message]
2002-05-23  5:36 ` Eli Zaretskii
2002-05-23 13:57   ` Jim Blandy
2002-05-24  5:20     ` Eli Zaretskii
2002-06-11 13:32     ` Jim Blandy

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20020522201700.952B45EA11@zwingli.cygnus.com \
    --to=jimb@redhat.com \
    --cc=gdb-patches@sources.redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox