HELLER@cs.umass.edu (Stride 440 User) (01/08/87)
> From: ZRGC002%DTUZDV5A.BITNET@WISCVM.WISC.EDU > Is there a PASCAL to C converter somewhere out there in the free domain. We > have a good C but no PASCAL. > I have a *simple* program (in C) which does much of the grunge work involved in converting Pascal source to C source. It does the context-dependent editing needed (i.e. converts ":=" to "=" and "=" to "==", "BEGIN" to "{", "END" to "}", "THEN" to "", "AND" to "&&", etc.). You still have to add in the "()" to parameterless functions, and re-hack the declaractions and I/O calls ("WRITE" & "WRITELN" become "printf" and "READ" & "READLN" become "scanf", but the arguments are left alone). Short of writing a Pascal compiler (which generates C code instead of machine code), this program probably does most of what you want. I take it this is a one-shot deal - that is you have some Pascal programs which you need to get running and need to translate them to C. Let me know if this program is usefull and I'll send it over the net (it is not very large). Robert Heller ARPANet: Heller@UMass-CS.CSNET BITNET: Heller@UMass.BITNET BIX: Heller GEnie: RHeller FidoNet: 101/27 (Dave's Fido, Gardner, MA) CompuServe 71450,3432 Local PV VAXen: COINS::HELLER UCC Cyber/DG: Heller@CS