Abstract data type and type-bound procedures in a static library?

Abstract data type and type-bound procedures in a static library?

Ritratto di JonD

I have a Fortran module that includes an abstract data type and its type-bound procedures (all are non-overridable). When I place this module in a static library and then link my main program to this library, the linker complains about not finding the type-bound procedures.  If I do away with the static library and add the module source code to my Visual Studio project directly, I get no problems and the resulting program runs fine.

Is this a compiler bug or an expected behavior? Can I not include abstract data types in a static library to be called later?

I am using VS 2010 with IVF version 13.0.1.119, Win 7 operating system.

Thanks for any help,

Jon

3 post / 0 new
Ultimo contenuto
Per informazioni complete sulle ottimizzazioni del compilatore, consultare l'Avviso sull'ottimizzazione
Ritratto di Steve Lionel (Intel)

Please attach a ZIP of a sample project showing the problem.

Steve
Ritratto di JonD

I wasn't able to replicate the problem with a simple test case. I went back and tried linking to the static library in my actual project and it worked this time. I don't know what changed but it looks like I can indeed include abstract data types in a static library.

Jon

Accedere per lasciare un commento.