[gdb/doc] Fix address location with file prefix
In the docs I read [1]:
...
Address locations indicate a specific program address. They have the
generalized form *address.
funcaddr
An address of a function or procedure derived from its name.
...
'filename':funcaddr
Like funcaddr above, but also specifies the name of the source file
explicitly. This is useful if the name of the function does not specify
the function unambiguously, e.g., if there are several functions with
identical names in different source files.
...
This is incorrect, the notation is in fact 'filename'::funcaddr.
Fix this by correcting the typo, and add a reference to "variable name
conflict", where the concept is explained in more detail.
Approved-By: Eli Zaretskii <eliz@gnu.org>
PR gdb/32748
Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=32748
[1] https://sourceware.org/gdb/current/onlinedocs/gdb.html/Address-Locations.html
diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo
index f064645..3c0d6de 100644
--- a/gdb/doc/gdb.texinfo
+++ b/gdb/doc/gdb.texinfo
@@ -9697,11 +9697,12 @@
This form specifies the address of the function's first instruction,
before the stack frame and arguments have been set up.
-@item '@var{filename}':@var{funcaddr}
+@item '@var{filename}'::@var{funcaddr}
Like @var{funcaddr} above, but also specifies the name of the source
file explicitly. This is useful if the name of the function does not
specify the function unambiguously, e.g., if there are several
-functions with identical names in different source files.
+functions with identical names in different source files,
+see @ref{variable name conflict}.
@end table
@node Edit
@@ -11000,6 +11001,7 @@
examine the variable @code{b} while your program is executing inside
the block where @code{b} is declared.
+@anchor{variable name conflict}
@cindex variable name conflict
There is an exception: you can refer to a variable or function whose
scope is a single source file even if the current execution point is not