gfortrans handling of type bound procedures of polymorphic types

Tilo Schwarz tilo@tilo-schwarz.de
Mon Apr 8 20:26:00 GMT 2013


On Mon, 08 Apr 2013 22:09:52 +0200, Tobias Burnus <burnus@net-b.de> wrote:

> Hi all,
>
> Tilo Schwarz wrote:
>> since I currently "explore" the Fortran OOP features I was wondering,  
>> how gfortran handles type bound procedures of polymorphic types. So the  
>> one question is (just out of curiosity): Are the polymorphic features  
>> of Fortran handled by the same mechanisms which are used for C++? So if  
>> I define a polymorphic type and attach a procedure which is overridden  
>> in a derived type - does this look like the equivalent C++ (virtual  
>> function) definition at some point in the compiler (midend?)
>
> Yes and no. The way Fortran (the language) implements it is surely  
> influenced by how C++ does it, though I believe it was more influenced  
> by other languages.
[...]

Thank you for your very detailed answer!

Regards,

	Tilo



More information about the Fortran mailing list