]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
[gdb/doc] Don't advertise *&function for pascal and modula-2
authorTom de Vries <tdevries@suse.de>
Mon, 3 Mar 2025 16:13:20 +0000 (17:13 +0100)
committerTom de Vries <tdevries@suse.de>
Mon, 3 Mar 2025 16:13:20 +0000 (17:13 +0100)
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.
    ...
    In Pascal and Modula-2, this is &function.
...

I tried "break *&function" for Pascal and Modula-2, and this doesn't work,
while "break *function" works fine.

Fix this by updating the documentation to reflect actual behaviour.

Approved-By: Eli Zaretskii <eliz@gnu.org>
PR gdb/32754
Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=32754

[1] https://sourceware.org/gdb/current/onlinedocs/gdb.html/Address-Locations.html

gdb/doc/gdb.texinfo

index 29c0118dda21da6900c028451b21cd952bace219..f064645a2fa4393a9105c929561353fe2fc9774b 100644 (file)
@@ -9689,11 +9689,10 @@ Any expression valid in the current working language.
 
 @item @var{funcaddr}
 An address of a function or procedure derived from its name.  In C,
-C@t{++}, Objective-C, Fortran, minimal, and assembly, this is
+C@t{++}, Objective-C, Fortran, Pascal, Modula-2, minimal, and assembly, this is
 simply the function's name @var{function} (and actually a special case
-of a valid expression).  In Pascal and Modula-2, this is
-@code{&@var{function}}.  In Ada, this is @code{@var{function}'Address}
-(although the Pascal form also works).
+of a valid expression).  In Ada, this is @code{@var{function}'Address}
+(although @code{&@var{function}} also works).
 
 This form specifies the address of the function's first instruction,
 before the stack frame and arguments have been set up.