Should I convert FORTRAN code to C?

Doug Gwyn gwyn at brl-smoke.ARPA
Mon Jun 13 08:42:06 AEST 1988


In article <522 at white.gcm> dc at white.UUCP (Dave Caswell) writes:
>How does the compiler know that I will be linking with the standard library?
>Does ANSI C allows compilers to "know" what these functions mean?
>I wasn't aware that any of those functions were part of the C language.

ANSI C distinguishes between "freestanding" and "hosted" implementations.
(How you invoke either of these depends on the particular implementation;
it's beyond the scope of the Standard for it to specify this.)

A Standard-conforming hosted implementation provides a comfortably large
set of standard library functions, and furthermore these external names
are all reserved for the implementation.  Therefore the compiler is free
to treat the standard library functions as intrinsics whenever that would
make sense.

The lack of a standard library for hosted applications was one of the
most glaring deficiencies in existing practice and thus one of the first
things X3J11 decided to fix.  (Actually /usr/group made a start on this.)



More information about the Comp.lang.c mailing list