Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

Programming modules

jaeger0
Beginner
374 Views

Hi

I'm writing on a bigger project, where I use an amount of modules, so sometimes I got problems to check the dependenciy.

Usually I include the required modules only in the functions of the module itself. So checking the dependencies, I have to go through all functions of the module.

However it would be nice if I just include all required modules in the head of the module(I'm currently programming).

I know, this is possible, but however makes the compiler any difference in it. So is there a difference if i include all required modules in the head of the module, or if I include the corresponding modules only in the subroutines, where they are required ?

Thanks for any comments

Martin

0 Kudos
1 Reply
Steven_L_Intel1
Employee
374 Views
It is a better programming practice to USE only those modules you need. As for the compiler, the fewer modules it has to read during compilation, the faster it can compile.
0 Kudos
Reply