Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
Announcements
FPGA community forums and blogs on community.intel.com are migrating to the new Altera Community and are read-only. For urgent support needs during this transition, please visit the FPGA Design Resources page or contact an Altera Authorized Distributor.

Integer type coercion

hendrixf
Beginner
704 Views

I used the Fortran Module Wizard in Intel 9.1to create a fortran wrapper file. The wrapper file mapped IDL enumerations to INTEGER::PARAMETER types. My problem is that the functions that use the enumerations expect INTEGER*2 types so the compiler can't resolve the arguments and I get the warning listed below.

The data type of the actual argument does not match the definition

One way to resolve this is to use the INT2() type conversion function to clear the warnings but this is pretty cumbersome since there are a lot of calls that I would have to change. Alternatively, I could edit the .f90 file created by the module wizard to define the types correctly but I would have to do this everytime I create the file.

Is there a way to coerce the compiler to treat the parameter statements as INTEGER*2 or can I configure the module wizard to force INTEGER*2 parameter statements?

Thanks,
Fred

0 Kudos
2 Replies
Steven_L_Intel1
Employee
704 Views
No to both questions, I'm afraid. I recognize that this is a major annoyance and am working with the developers to come up with a good solution.
0 Kudos
jimdempseyatthecove
Honored Contributor III
704 Views

Have you considered using the Fortran Pre-Processor?

e.g.

#define SOMEFUNCTION(a,b) SomeFunction(INT2(a),INT2(b))

Where you tweek the case (letting FORTRAN upcase the function name).

Jim Dempsey

0 Kudos
Reply