On Tue, Aug 26, 2025 at 08:37:56PM +0200, наб wrote:
> Package: cproto
> Version: 4.7x-1
> Severity: normal
> 
> Dear Maintainer,
> 
> If you dget src:tgif 1:4.2.5-2 and run
>   cproto -{P,F,C}"int f(a, b)" exec.c
> you'll get a dump of the prototypes.
> 
> If you run
>   cproto -a -{P,F,C}"int f(a, b)" exec.c
> you'll instead get a lot of output,
> /some/ prototypes changed,
> but that output ends with
>   exec.c:10428: syntax error at token ''

agreed - it's not going to work.  The updated manpage says

       The program does not pipe the source files through the  C  preprocessor
       when  it is converting function definitions (i.e., options -a, -b, -t).
       That is because cproto does the conversion by replacing strings, rather
       than by converting to/from lexical tokens.  Instead of using the C pre‐
       processor, cproto tries to handle preprocessor  directives  and  macros
       itself,  to  find type definitions.  There are several limitations as a
       result:

       •   the search-path for included files contains only “/usr/include” and
           the directories listed by “-I” options.

       •   conditional directives (e.g., “#if”) are ignored.

       •   only macros without parameters are handled.

       •   some comments in the function definition head are discarded.

-- 
Thomas E. Dickey <[email protected]>
https://invisible-island.net

Attachment: signature.asc
Description: PGP signature

Reply via email to