Path: utzoo!attcan!uunet!taumet!steve From: steve@taumet.com (Stephen Clamage) Newsgroups: comp.lang.c Subject: Re: XXX -> C Message-ID: <307@taumet.com> Date: 7 Jul 90 22:21:11 GMT References: <55422@lanl.gov> Reply-To: steve@taumet.UUCP (Stephen Clamage) Organization: Taumetric Corporation, San Diego Lines: 30 In article <55422@lanl.gov> rdw2030@venus.tamu.edu (Mark C. Lowe) writes: >I've never used a converter before, but I've heard about what they do. What >kind of performance (or lack thereof) have the readers of this group seen? I've written converters and used commercial and PD converters. A converter should leave comments more or less intact, but deciding where to put comments is not trivial. If the new language is at the same or lower semantic level, the bulk of conversion can be pretty good if the converter author is competent. If the new language is at a higher level, the conversion is going to be of poor quality. (Imagine going from FORTRAN 66 to C, and not having loops or data structures in the original -- the result is going to be very poor C code.) No matter how good the translation, there will be substantial hand work to make the program look right. Apart from formatting and putting the comments in the right places, the coding style won't look right. One problem area is the run-time library. FORTRAN has functions which have no counterpart in C. So do BASIC and Pascal. More hand work here. When you have a substantial program (many of thousands of lines), a good translator to take care of 85% of the simple stuff is very cost-effective. Rewriting the program is not always feasible. -- Steve Clamage, TauMetric Corp, steve@taumet.com