These are chat archives for Fortran-FOSS-Programmers/General-Discussion

17th
Jun 2016
Stefano Zaghi
@szaghi
Jun 17 2016 04:17
@cmacmackin I disagree. In FOODIE the deferred method for the ODE time derivative as an optional argument, the time t. It reflects very well that the residual function can or cannot explicitely depend on time. If the concrete ODE has U_t=R(U(t)) than you will not pass t to the method %time_derivative, on the contrary if U_t=R(U(t), t)) you will pass t. So, the API is not unique, but the usefulness of having an abstract is tremendus. I am not so rigorous in exploiting abstract.
Chris MacMackin
@cmacmackin
Jun 17 2016 07:26
That may be areasonable exception. What I'm objecting to is more the idea of using one optional argument in one implementation and a different one in another. At that point i I don't see the point of using a deferred procedure.
Stefano Zaghi
@szaghi
Jun 17 2016 08:34
@cmacmackin :+1: right, I agree with this concept. Indeed, I think at the deferred as a contract: concretes MUST give me this deferred, I could be not aware what you do inside it (thus optionals), but give me it... yes there is space for bad programming...