[net.lang.c] 'fortran' keyword query

ks@ecn-ee.UUCP (02/17/84)

#N:ecn-ee:13100009:000:658
ecn-ee!ks    Feb 16 23:01:00 1984

Does anyone really know what the fortran keyword is supposed to do..
The 4.2BSD C compiler will let you declare a function as type fortran
then just treats it the same as a function of type int..

If you try to use it to declare a variable,
you get the following error message:

"ks.c", line 4: fortran declaration must apply to function

Extrapolating a little, is this keyword intended to be used to declare
an external function as fortran so the compiler uses a different calling
procedure (call by reference, adding a '_' after the function name, etc.)?
But no one really has ever bothered to implement it??

Any ideas???

					Kirk Smith
					Purdue EE

henry@utzoo.UUCP (Henry Spencer) (02/21/84)

I believe there is or was at least one compiler within Bell that
did indeed use the "fortran" keyword to generate a different,
fortran-compatible calling sequence.  (Probably a non-recursive
sequence for a relatively old machine.)
-- 
				Henry Spencer @ U of Toronto Zoology
				{allegra,ihnp4,linus,decvax}!utzoo!henry