Re: GDB version as convenience variable

Simon Marchi
2019-03-25T17:58:25Z

On 2019-03-25 1:31 p.m., Eli Zaretskii wrote:
> --- a/gdb/doc/gdb.texinfo
> +++ b/gdb/doc/gdb.texinfo
> @@ -11211,6 +11211,17 @@
> @item $_gthread
> The global number of the current thread. @xref{global thread numbers}.
>
> +@item $_gdb_major
> +@itemx $_gdb_minor
> +@vindex $_gdb_major@{, convenience variable}
> +@vindex $_gdb_minor@{, convenience variable}
> +The major and minor version numbers of the running @value{GDBN}.
> +Development snapshots and pretest versions have their minor version
> +incremented by one; thus, @value{GDBN} pretest 9.11.90 will produce
> +the value 12 for @code{$_gdb_minor}. These variables allow you to
> +write scripts that work with different versions of @value{GDBN}
> +without errors caused by features unavailable in some of those
> +versions.
> @end table

I get this error when trying to "make html":

/home/smarchi/src/binutils-gdb/gdb/doc/gdb.texinfo:11216: misplaced }
/home/smarchi/src/binutils-gdb/gdb/doc/gdb.texinfo:11217: misplaced }

Is it worth having a test for that? If we check that they have the
expected value, it would be something to change when a new GDB branch is
created, probably (as the master branch will now represent the next
version). Maybe our release manager should have a say in this :).

Otherwise, this LGTM.

Simon