Article View: gnu.gcc.help
Article #49521Re: Automatic translate C code to C++
From: Lawrence Kirby
Date: Thu, 20 Jan 1994 15:12
Date: Thu, 20 Jan 1994 15:12
31 lines
1644 bytes
1644 bytes
In article <1994Jan19.004931.2532@bnrmtl.bnr.ca>
yongliu@NTPSERVER "Yong Liu" writes:
>There exist some small differences between C code and C++ code. For example,
>in C we write
> double g(x,y)
> double x,y;
> {
> .........
> }
>
>while in C++ the above code is writen as
> double g(double x,double y)
> {
> .........
> }
>
This also works for ANSI C.
>If I want to reuse my old C codes with my new C++ codes, an automatic
>translator from C to C++ would be very useful.
>
>Is there such a nice translator around?
the gcc package comes with protoize which performs this sort of conversion.
-----------------------------------------
Lawrence Kirby | fred@genesis.demon.co.uk
Wilts, England | 70734.126@compuserve.com
-----------------------------------------
Technical Details
Message-ID:
<759078736snz@genesis.demon.co.uk>Path:
arc1-ca.pugleaf.net!gmd.de!xlink.net!sol.ctr.columbia.edu!math.ohio-state.edu!howland.reston.ans.net!pipex!dis.demon.co.uk!genesis.demon.co.uk!fredReferences:
<Jan.18.15.27.51.1994.2912@remus.rutgers.edu> <1994Jan19.004931.2532@bnrmtl.bnr.ca>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 11318c,b791bfb1a70a6bc7 X-Google-Attributes: gid11318c,public X-Google-ArrivalTime: 1994-01-20 16:03:20 PST Newsgroups: gnu.gcc.help From: fred@genesis.demon.co.uk (Lawrence Kirby) Path: arc1-ca.pugleaf.net!gmd.de!xlink.net!sol.ctr.columbia.edu!math.ohio-state.edu!howland.reston.ans.net!pipex!dis.demon.co.uk!genesis.demon.co.uk!fred Subject: Re: Automatic translate C code to C++ References: <Jan.18.15.27.51.1994.2912@remus.rutgers.edu> <1994Jan19.004931.2532@bnrmtl.bnr.ca> Organization: none Reply-To: fred@genesis.demon.co.uk X-Newsreader: Demon Internet Simple News v1.27 Lines: 31 Date: Thu, 20 Jan 1994 15:12:16 +0000 Message-ID: <759078736snz@genesis.demon.co.uk> Sender: usenet@demon.co.uk