home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #26 / NN_1992_26.iso / spool / comp / lang / c / 16344 < prev    next >
Encoding:
Text File  |  1992-11-11  |  2.7 KB  |  52 lines

  1. Newsgroups: comp.lang.c
  2. Path: sparky!uunet!ferkel.ucsb.edu!taco!gatech!darwin.sura.net!zaphod.mps.ohio-state.edu!cs.utexas.edu!csc.ti.com!tilde.csc.ti.com!mksol!mccall
  3. From: mccall@mksol.dseg.ti.com (fred j mccall 575-3539)
  4. Subject: Re: Fortran to C conversion: Why bother?
  5. Message-ID: <1992Nov11.172747.1959@mksol.dseg.ti.com>
  6. Organization: Texas Instruments Inc
  7. References: <1992Nov9.131601.167@gems.vcu.edu> <20849@fritz.filenet.com>
  8. Date: Wed, 11 Nov 1992 17:27:47 GMT
  9. Lines: 41
  10.  
  11. In <20849@fritz.filenet.com> scotth@felix.filenet.com (Scott Hopson) writes:
  12.  
  13. >Keywords
  14. >In article <1992Nov9.131601.167@gems.vcu.edu> hleaves@gems.vcu.edu writes:
  15. >>I was wondering why anyone would bother using the f2c (or similar) program to
  16. >>translate fortran code directly into C. All you end up with is C code that
  17. >>exactly mimics the functionality of the original fortran code. Its not as if
  18. >>the translating program rewrites your algorithms to use the parts of C that
  19. >>make C really useful. Its just fortran code expressed in C. What's the point?
  20. >>If you're going to write programs in fortran, use a fortran compiler. If you
  21. >>want to use the features of C, learn C and use a C compiler. Using f2c doesnt
  22. >>give you any of the advantages of designing and writing the original program 
  23. >>in C.
  24.  
  25. >Let's say your company was moving from a system like an IBM running MVS or a 
  26. >DEC running VMS or some other similar beast to a Unix machine. You had lots of
  27. >OLD code which was written in FORTRAN but your new environment was going
  28. >strictly C and you knew there might be a need to maintain the OLD code, but you
  29. >lost all your Hard Core Fortran Oldtimers.
  30.  
  31. >What would you decide to do?
  32.  
  33. >Many companies think seriously about converting their old code into new code,
  34. >even if the functionality is the same. This is because they usually want the
  35. >same functionality but with the opportunity to enhance old systems.
  36.  
  37. The problem with this decision is that the code resulting from
  38. automatic translations is usually something less than maintainable, so
  39. you would still have to either maintain the FORTRAN or reimplement in
  40. maintainable C.  Converters are useful for those cases where you need
  41. to get the first release of a product out the door when you are in a
  42. new environment, but IMHO trying to maintain the output of a converter
  43. after chucking the original code is rather like maintaining object
  44. after chucking the source code.  It is somewhat more difficult than taking
  45. the time to reimplement properly in the new language.
  46.  
  47. -- 
  48. "Insisting on perfect safety is for people who don't have the balls to live
  49.  in the real world."   -- Mary Shafer, NASA Ames Dryden
  50. ------------------------------------------------------------------------------
  51. Fred.McCall@dseg.ti.com - I don't speak for others and they don't speak for me.
  52.