Don't use chew comments for static functions

I found a few static functions in the BFD manual.  These can't be
called by any user of the library, so I don't think it's useful to put
them in the manual.  This patch removes the chew markup from their
comments.

2023-02-17  Tom Tromey  <tom@tromey.com>

	* opncls.c (bfd_get_debug_link_info_1, separate_debug_file_exists)
	(separate_alt_debug_file_exists, find_separate_debug_file)
	(get_build_id, get_build_id_name, check_build_id_file): Don't use
	chew comments.
This commit is contained in:
Tom Tromey
2023-02-17 12:12:11 -07:00
parent ee0e172301
commit 2070491c1c
2 changed files with 57 additions and 118 deletions

View File

@ -1,3 +1,10 @@
2023-02-17 Tom Tromey <tom@tromey.com>
* opncls.c (bfd_get_debug_link_info_1, separate_debug_file_exists)
(separate_alt_debug_file_exists, find_separate_debug_file)
(get_build_id, get_build_id_name, check_build_id_file): Don't use
chew comments.
2023-02-17 Tom Tromey <tom@tromey.com> 2023-02-17 Tom Tromey <tom@tromey.com>
* doc/doc.str (SYNOPSIS): Use collapse_whitespace. * doc/doc.str (SYNOPSIS): Use collapse_whitespace.

View File

@ -1171,15 +1171,7 @@ bfd_calc_gnu_debuglink_crc32 (unsigned long crc,
} }
/* /* Extracts the filename and CRC32 value for any separate debug
INTERNAL_FUNCTION
bfd_get_debug_link_info_1
SYNOPSIS
char *bfd_get_debug_link_info_1 (bfd *abfd, void *crc32_out);
DESCRIPTION
Extracts the filename and CRC32 value for any separate debug
information file associated with @var{abfd}. information file associated with @var{abfd}.
The @var{crc32_out} parameter is an untyped pointer because The @var{crc32_out} parameter is an untyped pointer because
@ -1192,8 +1184,7 @@ DESCRIPTION
corresponding CRC32 value for the file. corresponding CRC32 value for the file.
The returned filename is allocated with @code{malloc}; freeing The returned filename is allocated with @code{malloc}; freeing
it is the responsibility of the caller. it is the responsibility of the caller. */
*/
static char * static char *
bfd_get_debug_link_info_1 (bfd *abfd, void *crc32_out) bfd_get_debug_link_info_1 (bfd *abfd, void *crc32_out)
@ -1328,22 +1319,12 @@ bfd_get_alt_debug_link_info (bfd * abfd, bfd_size_type *buildid_len,
return name; return name;
} }
/* /* Checks to see if @var{name} is a file and if its contents match
INTERNAL_FUNCTION @var{crc32}, which is a pointer to an @code{unsigned long}
separate_debug_file_exists containing a CRC32.
SYNOPSIS The @var{crc32_p} parameter is an untyped pointer because this
bool separate_debug_file_exists routine is used as a @code{check_func_type} function. */
(char *name, void *crc32_p);
DESCRIPTION
Checks to see if @var{name} is a file and if its contents
match @var{crc32}, which is a pointer to an @code{unsigned
long} containing a CRC32.
The @var{crc32_p} parameter is an untyped pointer because
this routine is used as a @code{check_func_type} function.
*/
static bool static bool
separate_debug_file_exists (const char *name, void *crc32_p) separate_debug_file_exists (const char *name, void *crc32_p)
@ -1371,17 +1352,7 @@ separate_debug_file_exists (const char *name, void *crc32_p)
return crc == file_crc; return crc == file_crc;
} }
/* /* Checks to see if @var{name} is a file. */
INTERNAL_FUNCTION
separate_alt_debug_file_exists
SYNOPSIS
bool separate_alt_debug_file_exists
(char *name, void *unused);
DESCRIPTION
Checks to see if @var{name} is a file.
*/
static bool static bool
separate_alt_debug_file_exists (const char *name, void *unused ATTRIBUTE_UNUSED) separate_alt_debug_file_exists (const char *name, void *unused ATTRIBUTE_UNUSED)
@ -1399,17 +1370,7 @@ separate_alt_debug_file_exists (const char *name, void *unused ATTRIBUTE_UNUSED)
return true; return true;
} }
/* /* Searches for a debug information file corresponding to @var{abfd}.
INTERNAL_FUNCTION
find_separate_debug_file
SYNOPSIS
char *find_separate_debug_file
(bfd *abfd, const char *dir, bool include_dirs,
get_func_type get, check_func_type check, void *data);
DESCRIPTION
Searches for a debug information file corresponding to @var{abfd}.
The name of the separate debug info file is returned by the The name of the separate debug info file is returned by the
@var{get} function. This function scans various fixed locations @var{get} function. This function scans various fixed locations
@ -1424,8 +1385,7 @@ DESCRIPTION
Returns the filename of the first file to be found which Returns the filename of the first file to be found which
receives a TRUE result from the @var{check} function. receives a TRUE result from the @var{check} function.
Returns NULL if no valid file could be found. Returns NULL if no valid file could be found. */
*/
typedef char * (*get_func_type) (bfd *, void *); typedef char * (*get_func_type) (bfd *, void *);
typedef bool (*check_func_type) (const char *, void *); typedef bool (*check_func_type) (const char *, void *);
@ -1824,23 +1784,14 @@ bfd_fill_in_gnu_debuglink_section (bfd *abfd,
return true; return true;
} }
/* /* Finds the build-id associated with @var{abfd}. If the build-id is
INTERNAL_FUNCTION
get_build_id
SYNOPSIS
struct bfd_build_id * get_build_id (bfd *abfd);
DESCRIPTION
Finds the build-id associated with @var{abfd}. If the build-id is
extracted from the note section then a build-id structure is built extracted from the note section then a build-id structure is built
for it, using memory allocated to @var{abfd}, and this is then for it, using memory allocated to @var{abfd}, and this is then
attached to the @var{abfd}. attached to the @var{abfd}.
Returns a pointer to the build-id structure if a build-id could be Returns a pointer to the build-id structure if a build-id could be
found. If no build-id is found NULL is returned and error code is found. If no build-id is found NULL is returned and error code is
set. set. */
*/
static struct bfd_build_id * static struct bfd_build_id *
get_build_id (bfd *abfd) get_build_id (bfd *abfd)
@ -1925,25 +1876,15 @@ get_build_id (bfd *abfd)
return build_id; return build_id;
} }
/* /* Searches @var{abfd} for a build-id, and then constructs a pathname
INTERNAL_FUNCTION
get_build_id_name
SYNOPSIS
char * get_build_id_name (bfd *abfd, void *build_id_out_p)
DESCRIPTION
Searches @var{abfd} for a build-id, and then constructs a pathname
from it. The path is computed as .build-id/NN/NN+NN.debug where from it. The path is computed as .build-id/NN/NN+NN.debug where
NNNN+NN is the build-id value as a hexadecimal string. NNNN+NN is the build-id value as a hexadecimal string.
Returns the constructed filename or NULL upon error. Returns the constructed filename or NULL upon error. It is the
It is the caller's responsibility to free the memory used to hold the caller's responsibility to free the memory used to hold the
filename. filename. If a filename is returned then the @var{build_id_out_p}
If a filename is returned then the @var{build_id_out_p} parameter (which points to a @code{struct bfd_build_id} pointer) is
parameter (which points to a @code{struct bfd_build_id} set to a pointer to the build_id structure. */
pointer) is set to a pointer to the build_id structure.
*/
static char * static char *
get_build_id_name (bfd *abfd, void *build_id_out_p) get_build_id_name (bfd *abfd, void *build_id_out_p)
@ -1987,21 +1928,12 @@ get_build_id_name (bfd *abfd, void *build_id_out_p)
return name; return name;
} }
/* /* Checks to see if @var{name} is a readable file and if its build-id
INTERNAL_FUNCTION
check_build_id_file
SYNOPSIS
bool check_build_id_file (char *name, void *buildid_p);
DESCRIPTION
Checks to see if @var{name} is a readable file and if its build-id
matches @var{buildid}. matches @var{buildid}.
Returns TRUE if the file exists, is readable, and contains a Returns TRUE if the file exists, is readable, and contains a
build-id which matches the build-id pointed at by build-id which matches the build-id pointed at by @var{build_id_p}
@var{build_id_p} (which is really a @code{struct bfd_build_id **}). (which is really a @code{struct bfd_build_id **}). */
*/
static bool static bool
check_build_id_file (const char *name, void *buildid_p) check_build_id_file (const char *name, void *buildid_p)