Automatic converters (K&R C => ANSI C) (K&R C => C++) (ANSI C => K&R C)

Ron Guilmette rfg at ics.uci.edu
Sat Oct 28 12:01:50 AEST 1989


In article <1004 at cirrusl.UUCP> dhesi%cirrusl at oliveb.ATC.olivetti.com (Rahul Dhesi) writes:
>In article <1989Oct22.113105.29034 at paris.ics.uci.edu> rfg at ics.uci.edu
>(Ron Guilmette) writes:
>>	Protoize is a tool which assists in the conversion of
>>	old style (K&R) C code to new style (ANSI) C code or to
>>	C++ code.
>
>What I really need is a tool that takes either
>
>     int xyz(char *c, FILE *f);
>
>or
>
>     int xyz();
>
>and produces:
>
>     #ifdef ANSIPROTO
>      int xyz(char *c, FILE *f);
>     #else
>      int xyz();
>     #endif

Many people have asked for this effect.  Please note that you can create such
"composite" files yourself if you have a version of "diff" which supports
the -D option.  The SunOS "diff" does.  I hope that somebody will implement
this in GNU diff soon.

// rfg



More information about the Comp.lang.c mailing list