gdb/doc: fix a makeinfo warning

Message ID OS3P286MB21522A5C290212D8E2E6E363F0489@OS3P286MB2152.JPNP286.PROD.OUTLOOK.COM
State New
Headers
Series gdb/doc: fix a makeinfo warning |

Commit Message

Enze Li May 31, 2023, 2:13 p.m. UTC
  I see this warning when compiling GDB,

  gdb.texinfo:5975: warning: undefined flag: GDB
  gdb.texinfo:5976: warning: undefined flag: GDB

and consequently I see the misprints in doc/gdb/Dynamic-Printf.html as
follow,

  ...Most of {No value for ‘GDB’}’s format specifiers...

Fix this by using '@value{GDBN}' instead of '@value{GDB}'.
---
 gdb/doc/gdb.texinfo | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)


base-commit: 6e9bcaad3fd8f7635afb9fa7013762da2eeff8e5
  

Comments

Tom Tromey May 31, 2023, 2:40 p.m. UTC | #1
>>>>> "Enze" == Enze Li via Gdb-patches <gdb-patches@sourceware.org> writes:

Enze> I see this warning when compiling GDB,
Enze>   gdb.texinfo:5975: warning: undefined flag: GDB
Enze>   gdb.texinfo:5976: warning: undefined flag: GDB

Enze> and consequently I see the misprints in doc/gdb/Dynamic-Printf.html as
Enze> follow,

Thanks.  I noticed this as well and I pushed a fix for it before I saw
yours.

Tom
  
Eli Zaretskii May 31, 2023, 2:54 p.m. UTC | #2
> Cc: enze.li@gmx.com
> Date: Wed, 31 May 2023 22:13:41 +0800
> From: Enze Li via Gdb-patches <gdb-patches@sourceware.org>
> 
> I see this warning when compiling GDB,
> 
>   gdb.texinfo:5975: warning: undefined flag: GDB
>   gdb.texinfo:5976: warning: undefined flag: GDB
> 
> and consequently I see the misprints in doc/gdb/Dynamic-Printf.html as
> follow,
> 
>   ...Most of {No value for ‘GDB’}’s format specifiers...
> 
> Fix this by using '@value{GDBN}' instead of '@value{GDB}'.
> ---
>  gdb/doc/gdb.texinfo | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo
> index 4bc83ed2168..a179af77224 100644
> --- a/gdb/doc/gdb.texinfo
> +++ b/gdb/doc/gdb.texinfo
> @@ -5972,8 +5972,8 @@ Handle the output by calling a function in your program (normally
>  @code{printf}).  When using this style the supported format specifiers
>  depend entirely on the function being called.
>  
> -Most of @value{GDB}'s format specifiers align with those supported by
> -the @code{printf} function, however, @value{GDB}'s @samp{%V} format
> +Most of @value{GDBN}'s format specifiers align with those supported by
> +the @code{printf} function, however, @value{GDBN}'s @samp{%V} format
>  specifier extension is not supported by @code{printf}.  When using
>  @samp{call} style dprintf, care should be taken to ensure that only
>  format specifiers supported by the output function are used, otherwise

Thanks, this is an "obvious fix".
  
Enze Li June 1, 2023, 1:34 a.m. UTC | #3
On Wed, May 31 2023 at 08:40:24 AM -0600, Tom Tromey wrote:

>>>>>> "Enze" == Enze Li via Gdb-patches <gdb-patches@sourceware.org> writes:
>
> Enze> I see this warning when compiling GDB,
> Enze>   gdb.texinfo:5975: warning: undefined flag: GDB
> Enze>   gdb.texinfo:5976: warning: undefined flag: GDB
>
> Enze> and consequently I see the misprints in doc/gdb/Dynamic-Printf.html as
> Enze> follow,
>
> Thanks.  I noticed this as well and I pushed a fix for it before I saw
> yours.
>
> Tom

Hi Tom,

It's okay to drop this one.  Anyway, thanks for fixing this.

Cheers!
Enze
  
Enze Li June 1, 2023, 1:42 a.m. UTC | #4
On Wed, May 31 2023 at 10:53:54 AM -0400, Eli Zaretskii wrote:

>> Cc: enze.li@gmx.com
>> Date: Wed, 31 May 2023 22:13:41 +0800
>> From: Enze Li via Gdb-patches <gdb-patches@sourceware.org>
>> 
>> I see this warning when compiling GDB,
>> 
>>   gdb.texinfo:5975: warning: undefined flag: GDB
>>   gdb.texinfo:5976: warning: undefined flag: GDB
>> 
>> and consequently I see the misprints in doc/gdb/Dynamic-Printf.html as
>> follow,
>> 
>>   ...Most of {No value for ‘GDB’}’s format specifiers...
>> 
>> Fix this by using '@value{GDBN}' instead of '@value{GDB}'.
>> ---
>>  gdb/doc/gdb.texinfo | 4 ++--
>>  1 file changed, 2 insertions(+), 2 deletions(-)
>> 
>> diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo
>> index 4bc83ed2168..a179af77224 100644
>> --- a/gdb/doc/gdb.texinfo
>> +++ b/gdb/doc/gdb.texinfo
>> @@ -5972,8 +5972,8 @@ Handle the output by calling a function in your program (normally
>>  @code{printf}).  When using this style the supported format specifiers
>>  depend entirely on the function being called.
>>  
>> -Most of @value{GDB}'s format specifiers align with those supported by
>> -the @code{printf} function, however, @value{GDB}'s @samp{%V} format
>> +Most of @value{GDBN}'s format specifiers align with those supported by
>> +the @code{printf} function, however, @value{GDBN}'s @samp{%V} format
>>  specifier extension is not supported by @code{printf}.  When using
>>  @samp{call} style dprintf, care should be taken to ensure that only
>>  format specifiers supported by the output function are used, otherwise
>
> Thanks, this is an "obvious fix".

Hi Eli,

It is necessary to be cautious for a new contributor.  Thank you for your
guidance, next time I will carefully try to submit such obvious errors.

Best Regards,
Enze
  

Patch

diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo
index 4bc83ed2168..a179af77224 100644
--- a/gdb/doc/gdb.texinfo
+++ b/gdb/doc/gdb.texinfo
@@ -5972,8 +5972,8 @@  Handle the output by calling a function in your program (normally
 @code{printf}).  When using this style the supported format specifiers
 depend entirely on the function being called.
 
-Most of @value{GDB}'s format specifiers align with those supported by
-the @code{printf} function, however, @value{GDB}'s @samp{%V} format
+Most of @value{GDBN}'s format specifiers align with those supported by
+the @code{printf} function, however, @value{GDBN}'s @samp{%V} format
 specifier extension is not supported by @code{printf}.  When using
 @samp{call} style dprintf, care should be taken to ensure that only
 format specifiers supported by the output function are used, otherwise