This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[patch] typeprint.c (_initialize_typeprint): Improve type help text.


Hi.
I will check this in after sourceware.org comes back online
if there are no objections.

The online help text for ptype is incomplete.
The usage syntax mentions expressions but the prose does not.
And neither the usage syntax nor the prose allows for, e.g.,
"ptype const char * const *".

2013-03-19  Doug Evans  <dje@google.com>

	* typeprint.c (_initialize_typeprint): Improve type help text.

Index: typeprint.c
===================================================================
RCS file: /cvs/src/src/gdb/typeprint.c,v
retrieving revision 1.52
diff -u -p -r1.52 typeprint.c
--- typeprint.c	1 Jan 2013 06:41:29 -0000	1.52
+++ typeprint.c	19 Mar 2013 17:42:13 -0000
@@ -684,9 +684,10 @@ _initialize_typeprint (void)
 
   c = add_com ("ptype", class_vars, ptype_command, _("\
 Print definition of type TYPE.\n\
-Usage: ptype[/FLAGS] TYPE-NAME | EXPRESSION\n\
-Argument may be a type name defined by typedef, or \"struct STRUCT-TAG\"\n\
-or \"class CLASS-NAME\" or \"union UNION-TAG\" or \"enum ENUM-TAG\".\n\
+Usage: ptype[/FLAGS] TYPE | EXPRESSION\n\
+Argument may be any type (for example a type name defined by typedef,\n\
+or \"struct STRUCT-TAG\" or \"class CLASS-NAME\" or \"union UNION-TAG\"\n\
+or \"enum ENUM-TAG\") or an expression.\n\
 The selected stack frame's lexical context is used to look up the name.\n\
 Contrary to \"whatis\", \"ptype\" always unrolls any typedefs.\n\
 \n\


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]