Silverfrost Forums

Welcome to our forums

Fortran 2003 extensions

21 Aug 2013 3:52 #12909

Excellent - seems to be working.

thank you.

now, any chance of allowing /undef to work under windows 7/64 bit? 😉

K

21 Aug 2013 4:42 #12910

In what sense does /undef not work?

3 Sep 2013 7:51 (Edited: 3 Sep 2013 7:56) #12967

Quoted from KennyT We are being reluctantly forced into producing a version of our apps built on Intel Visual Fortran and its handling of Modules is 'different', such that an 'IMPORT' statement (apparently an f2003 extension) is needed in various places, which is unnecessary in FTN95...

Is there any way to have the FTN95 compiler ignore any 'IMPORT' statements so we can minimise the differences between our source files?

K

Further to this, another 'conflict' is the syntax for STDCALL. Is there an equivalent '!' syntax for STDCALL (similar to !ftn95$free) that would be recognizable by FTN95 but ignored by IVF. IVF uses a complex sequence of !DEC$ATTRIBUTES lines, which are, thankfully, ignored by FTN95...

K

edit, I can see a reference to !FTN95$STDCALL in the help, but no example of its use and abuse - anyone used it?

3 Sep 2013 7:52 #12968

Quoted from PaulLaidler In what sense does /undef not work?

further to my PM, we're still trying to make the problem happen in a test routine, but it steadfastly refuses to fall over!

K

3 Sep 2013 11:58 #12970

!FTN95$STDCALL provides an alternative to F_STDCALL which is not the same as STDCALL which is used, for example, in win32api.ins to access C library functions.

If your context is an include file like win32api.ins then having a comment embedded directive for STDCALL will not help because the whole of the binding will be unacceptable to Intel Fortran.

3 Sep 2013 4:42 #12976

Quoted from PaulLaidler !FTN95$STDCALL provides an alternative to F_STDCALL which is not the same as STDCALL which is used, for example, in win32api.ins to access C library functions.

If your context is an include file like win32api.ins then having a comment embedded directive for STDCALL will not help because the whole of the binding will be unacceptable to Intel Fortran.

Hi Paul,

we use STDCALL to access some 3rd party DLLs:

 stdcall Lexus_ 'Lexus' (STRING, REF)

in IVF, we have to put:

!DEC$ATTRIBUTES STDCALL, DLLIMPORT  :: Lexus
!DEC$ATTRIBUTES DECORATE, ALIAS:'Lexus'  :: Lexus
!DEC$ATTRIBUTES REFERENCE :: STR1, IE

which is ignored by FTN95, so i just wondered if there was an equivalent !FTN$... comment embedded version of STDCALL that would get ignored by IVF. As an equivalent example, we now have at the top of each source file:

!dec$freeform
!ftn95$free

so that both compilers recognise them as free format source.

K

4 Sep 2013 7:05 #12977

I can not find anything like this in the existing comment embedded directives. It could be added and I can put it on the wish list if you like.

For the moment you would need to use conditional compilation (e.g. /CFPP).

4 Sep 2013 7:59 #12979

Quoted from PaulLaidler I can not find anything like this in the existing comment embedded directives. It could be added and I can put it on the wish list if you like.

For the moment you would need to use conditional compilation (e.g. /CFPP).

yes please.

K

Please login to reply.