Re: array-valued function as dummy argument



In article <1172620511.812240@xxxxxxxxxxxxxxxxxx>,
harper@xxxxxxxxxxxxx (John Harper) wrote:

In f95, can one declare a dummy argument that is a function whose
value is an array, without having to write an interface block for it?

No. If the dummy function uses any of the new stuff beyond f77
(e.g. assumed shape arrays, derived types, intent, array valued
functions, etc.), then you must write an interface block and it is
up to the programmer to ensure that the actual interface matches the
interface block. Some compilers can check at compile time that the
actual argument interface matches the dummy argument interface, but
others don't.

$.02 -Ron Shepard
.



Relevant Pages

  • Re: the problem of declaring a function in the interface
    ... But the funny thing is that in the function precedure below, ... then that looks like it supports the allocatable function procedure. ... When I take "allocatable" out in the interface block and the function ... I just need a function result array. ...
    (comp.lang.fortran)
  • Re: ruby style blocks in java
    ... public void doSomething() { ... Array a = new Array; ... the sort of thing you have above actually cut down the number of lines of Java code I had to write by factoring out a whole lot of JDBC try/finally code. ...
    (comp.lang.ruby)
  • Re: array-valued function as dummy argument
    ... value is an array, without having to write an interface block for it? ... In f2003 you could use a procedure statement to reference the interface ...
    (comp.lang.fortran)