From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13079 invoked by alias); 18 Feb 2006 09:27:31 -0000 Received: (qmail 13071 invoked by uid 22791); 18 Feb 2006 09:27:30 -0000 X-Spam-Check-By: sourceware.org Received: from romy.inter.net.il (HELO romy.inter.net.il) (192.114.186.66) by sourceware.org (qpsmtpd/0.31) with ESMTP; Sat, 18 Feb 2006 09:27:29 +0000 Received: from HOME-C4E4A596F7 (IGLD-84-228-139-42.inter.net.il [84.228.139.42]) by romy.inter.net.il (MOS 3.7.3-GA) with ESMTP id DOY10026 (AUTH halo1); Sat, 18 Feb 2006 11:26:58 +0200 (IST) Date: Sat, 18 Feb 2006 09:27:00 -0000 Message-Id: From: Eli Zaretskii To: fnf@diveadx.com CC: jimb@red-bean.com, gdb-patches@sourceware.org, fnf@specifix.com In-reply-to: <200602171531.27812.fnf@diveadx.com> (message from Fred Fish on Fri, 17 Feb 2006 15:31:27 -0500) Subject: Re: [PATCH] Fix ptype problem printing typedefs defined differently in different compilation units Reply-to: Eli Zaretskii References: <200601031517.50309.fnf@specifix.com> <200602161916.00761.fnf@diveadx.com> <200602171531.27812.fnf@diveadx.com> X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2006-02/txt/msg00342.txt.bz2 > From: Fred Fish > Date: Fri, 17 Feb 2006 15:31:27 -0500 > Cc: drow@false.org, jimb@red-bean.com, gdb-patches@sourceware.org, > fnf@specifix.com > > On Friday 17 February 2006 04:15, Eli Zaretskii wrote: > > Will the manual's description of the differences between these two > > commands be still valid after this change? > > Here is a patch for the doc change. Thanks. The doc patch is approved, but please take care of this minor issue: > @kindex whatis > @item whatis @var{expr} > ! @itemx whatis @var{typename} > ! @itemx whatis > ! Print the data type of expression @var{expr} or type @var{typename}. > ! @var{expr} is not actually evaluated, and any side-effecting operations > ! (such as assignments or function calls) inside it do not take place. > ! @var{typename} may be the name of a type or typedef, or for C code it may > ! have the form @samp{class @var{class-name}}, @samp{struct @var{struct-tag}}, > ! @samp{union @var{union-tag}} or @samp{enum @var{enum-tag}}. > ! Without any arguments, print the data type of @code{$}, the last value > ! in the value history. Now that you've unified the descriptions, there's no need to have a separate "@itemx whatis" without arguments, you can simply put the argument in the other two @item's in [], to show that they are optional. I would even leave only one @item, and modify the description slightly, like this: @item whatis [@var{arg}] Print the data type of expression @var{arg}, either an expression or a data type. With no argument, print the data type of @code{$}, ... If @var{arg} is an expression, it is not actually evaluated, ... If @var{arg} is a type name, it may be the name of a type or typedef, ... > @item ptype @var{expr} > + @itemx ptype @var{typename} > @itemx ptype > ! @code{ptype} accepts the same arguments as @code{whatis}, but prints a > ! detailed description of the type, instead of just the name of the type. > ! @xref{Expressions, ,Expressions}. Same here.