From: Jan Kratochvil <jan.kratochvil@redhat.com>
To: gdb-patches@sourceware.org
Subject: [help patch] whatis vs. ptype - the difference
Date: Wed, 27 Jul 2011 03:39:00 -0000 [thread overview]
Message-ID: <20110726213021.GA14823@host1.jankratochvil.net> (raw)
Hi,
just noticed the original user confusion came from the GDB help; not from the
GDB manual. So that it may be a bit pointed out there.
Wording review welcomed.
Thanks,
Jan
gdb/
2011-07-26 Jan Kratochvil <jan.kratochvil@redhat.com>
* typeprint.c (_initialize_typeprint): Extend the help of "whatis" and
"ptype" by their typedefs difference.
--- a/gdb/typeprint.c
+++ b/gdb/typeprint.c
@@ -316,8 +316,10 @@ _initialize_typeprint (void)
Print definition of type TYPE.\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\
-The selected stack frame's lexical context is used to look up the name."));
+The selected stack frame's lexical context is used to look up the name.\n\
+Contrary to \"whatis\", \"ptype\" always unrolls any typedefs."));
add_com ("whatis", class_vars, whatis_command,
- _("Print data type of expression EXP."));
+ _("Print data type of expression EXP.\n\
+Only one level of typedefs is unrolled. See also \"ptype\"."));
}
next reply other threads:[~2011-07-26 21:30 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-07-27 3:39 Jan Kratochvil [this message]
2011-07-27 17:41 ` [help patch] whatis vs. ptype - the difference #2 Jan Kratochvil
2011-07-27 17:41 ` Tom Tromey
2011-07-27 18:56 ` Jan Kratochvil
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=20110726213021.GA14823@host1.jankratochvil.net \
--to=jan.kratochvil@redhat.com \
--cc=gdb-patches@sourceware.org \
/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