Path: utzoo!attcan!uunet!seismo!sundc!pitstop!texsun!texsun.central.sun.com!convex!authorplaceholder From: hutchson@convex.UUCP Newsgroups: comp.lang.c Subject: Re: Should I convert FORTRAN code to C? Message-ID: <64400013@convex> Date: 1 Jul 88 18:33:00 GMT References: <2742@utastro.UUCP> Lines: 21 Nf-ID: #R:utastro.UUCP:-274200:convex:64400013:000:1029 Nf-From: convex.UUCP!hutchson Jul 1 13:33:00 1988 >Richard Harter, SMDS Inc., writes: >The issue really is -- what data types are supported by the language as >primitives. Any type which is a primitive language type can be compiled >much more efficiently than one which must be built up by hand. This is incontrovertable. >C has >characters and pointers as primitives; fortran has complex as a primitive. >C also has structures as a primitive. This is most inaccurate. C supports multiple lengths of integers (including a VERY short length unsuitable for anything larger than an ASCII character.) C "char's" are really wierdly-represented tiny ints. C has a well-defined library of operations on null-terminated character strings; but only with the advent of ANSI C will it be possible to consider character strings primitive. Fortran, on the other hand, DOES have character strings as primitives, and good compilers can generate inline code for many string operations. In addition, fortran has multiple lengths of floating-point values--ANSI C is adding this, I think.