[TUHS] C declarations.

Random832 random832 at fastmail.com
Sun May 14 05:08:12 AEST 2017


On Sat, May 13, 2017, at 08:35, Tim Bradshaw wrote:
> Are there languages that copy arrays in function calls defaultly? 
> Perhaps Fortran has some convention that allows that but I doubt it gets
> used very much, because it would be insane in most cases: 
> COMPUTE_MEAN_TEMPERATURE(ATMOS) is really *not* going to work very well
> if it involves copying the ATMOS array.

Fortran, for the record, passes nearly everything by reference - to call
a fortran function from C (or to make a C function callable from
fortran) you've got to mangle the name and change almost everything to
pointers.



More information about the TUHS mailing list