information about preprocessor macros.
* gdb/testsuite/lib/gdb.exp (get_debug_format): Tolerate message
saying whether preprocessor macro information is present.
* gdb/doc/gdb.texinfo (Symbols): Update documentation for `info
source' command.
2002-06-11 Jim Blandy <jimb@redhat.com>
+ * source.c (source_info): Mention whether the symtab has
+ information about preprocessor macros.
+
Call the command `info macro', not `show macro'.
* macrocmd.c (info_macro_command): Renamed from `show_macro_command'.
Fix error message.
2002-06-11 Jim Blandy <jimb@redhat.com>
+ * gdb.texinfo (Symbols): Update documentation for `info source'
+ command.
+
* gdb.texinfo (Macros): Call the command `info macro', not
`show macro'.
@kindex info source
@item info source
-Show the name of the current source file---that is, the source file for
-the function containing the current point of execution---and the language
-it was written in.
+Show information about the current source file---that is, the source file for
+the function containing the current point of execution:
+@itemize @bullet
+@item
+the name of the source file, and the directory containing it,
+@item
+the directory it was compiled in,
+@item
+its length, in lines,
+@item
+which programming language it is written in,
+@item
+whether the executable includes debugging information for that file, and
+if so, what format the information is in (e.g., STABS, Dwarf 2, etc.), and
+@item
+whether the debugging information includes information about
+preprocessor macros.
+@end itemize
+
@kindex info sources
@item info sources
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
2002-06-11 Jim Blandy <jimb@redhat.com>
+ * lib/gdb.exp (get_debug_format): Tolerate message saying whether
+ preprocessor macro information is present.
+
* macscp.exp, macscp1.c, macscp2.h, macscp3.h, macscp4.h: New
tests.
set debug_format "unknown"
send_gdb "info source\n"
gdb_expect 10 {
- -re "Compiled with (.*) debugging format.\r\n$gdb_prompt $" {
+ -re "Compiled with (.*) debugging format.\r\n.*$gdb_prompt $" {
set debug_format $expect_out(1,string)
verbose "debug format is $debug_format"
return 1;