Python/Fortran interoperability

nmm1 at cam.ac.uk nmm1 at cam.ac.uk
Mon Aug 24 10:24:50 CEST 2009


In article <5134d9f1-0e23-4e05-a817-bf0cc9e85d3e at w6g2000yqw.googlegroups.com>,
sturlamolden  <sturlamolden at yahoo.no> wrote:
>On 24 Aug, 02:26, nos... at see.signature (Richard Maine) wrote:
>
>> You missed the word "OOP", which seemed like the whole point. Not that
>> the particular word is used in the Fortran standard, but it isn't hard
>> to guess that he means a derived type that uses some of the OOP
>> features. Inheritance, polymorphism, and type-bound procedure (aka
>> methods in some other languages) come to mind.
>
>But C is not OOP. The ISO C bindings in Fortran are not ISO C++
>bindings. This is for a reason: C++ does not have a standard ABI like
>ISO C.

Nor does C.  Almost everything that most people believe about C is
wrong, because C is not well-defined at any level, so there are
many twisty little C languages, all different.

Richard is perfectly correct that my point was OOP.  C interoperability
does not apply to any derived type with type-bound procedures, which
include finalizers.  Note that this ALSO forbids them from being
passed as data, even if the other language never uses the OOP features
of the type.


Regards,
Nick Maclaren.



More information about the Python-list mailing list