bug-texinfo
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: declaring function pointers with explicit prototypes for the info re


From: Patrice Dumas
Subject: Re: declaring function pointers with explicit prototypes for the info reader
Date: Sun, 16 Jun 2024 17:37:48 +0200

On Sun, Jun 16, 2024 at 04:29:10PM +0200, Patrice Dumas wrote:
> Hello,
> 
> In standalone info reader code in info/ most function pointers are
> declared as a generic function pointer VFunction *, defined in info.h as
> 
> typedef void VFunction ();
> 
> I think that it would be much better to use actual prototypes depending
> on the functions to have type checking by the compiler. 

Here is a possible patch for the Info command functions, which seem to
all have the same prototype.  After that there only remains functions in
terminal.h and terminal.c, which all have diverse prototypes, but it is
easy to determine which one as the pointer and the default function are
declared at the same place.

-- 
Pat

Attachment: explicit_info_functions_type.diff
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]