- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
Hi,
I have a subroutine that USEs two modules where two UDTs are defined:
MODULE A
TYPE TypeA
!definitions here
END TYPE TypeA
END MODULE
MODULE B
TYPE TypeB
!defintions here
END TYPE TypeB
END MODULE
SUBROUTINE MySub(AA,BB)
USE A
USE B
IMPLICIT NONE
TYPE(TypeA),ALLOCATABLE::AA(:)
TYPE(TypeB),ALLOCATABLE::BB(:)
!Code here
END SUBROUTINE MySub
In the main program that calls MySub:
PROGRAM MAIN
USE A
USE B
IMPLICIT NONE
INTERFACE
SUBROUTINE MySub
USE A
USE B
IMPLICIT NONE
TYPE(TypeA),ALLOCATABLE::AA(:)
TYPE(TypeB),ALLOCATABLE::BB(:)
END SUBROUTINE MySub
END INTERFACE
!Code here
END
Now, when /gen-interface option is turned off the code compiles fine. When /gen-interface option is on I get an error that says "There is a conflict between local interface block and external interface block. [AA]". Can anyone explain what the possible cause of this error might be and why I get this error for AA but not BB?
The above code sample is just to explain the problem. The actual code and interface blocks are much more complicated. I checked both MODULE A and MODULE B to see if I can find any structural differences that may explain why I get this error only for AA; I couldn't find anything.
Thanks for any help in advance.
Jon
I have a subroutine that USEs two modules where two UDTs are defined:
MODULE A
TYPE TypeA
!definitions here
END TYPE TypeA
END MODULE
MODULE B
TYPE TypeB
!defintions here
END TYPE TypeB
END MODULE
SUBROUTINE MySub(AA,BB)
USE A
USE B
IMPLICIT NONE
TYPE(TypeA),ALLOCATABLE::AA(:)
TYPE(TypeB),ALLOCATABLE::BB(:)
!Code here
END SUBROUTINE MySub
In the main program that calls MySub:
PROGRAM MAIN
USE A
USE B
IMPLICIT NONE
INTERFACE
SUBROUTINE MySub
USE A
USE B
IMPLICIT NONE
TYPE(TypeA),ALLOCATABLE::AA(:)
TYPE(TypeB),ALLOCATABLE::BB(:)
END SUBROUTINE MySub
END INTERFACE
!Code here
END
Now, when /gen-interface option is turned off the code compiles fine. When /gen-interface option is on I get an error that says "There is a conflict between local interface block and external interface block. [AA]". Can anyone explain what the possible cause of this error might be and why I get this error for AA but not BB?
The above code sample is just to explain the problem. The actual code and interface blocks are much more complicated. I checked both MODULE A and MODULE B to see if I can find any structural differences that may explain why I get this error only for AA; I couldn't find anything.
Thanks for any help in advance.
Jon
Link kopiert
3 Antworten
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
Compiler version? I don't see this with 10.0.027.
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
Sorry! Compiler version is 10.0.027 with Visual Studio 2003.
Jon
Jon
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
Can you reproduce the problem with the code you posted, filling in a component into each of the derived types? I can't.
Antworten
Themen-Optionen
- RSS-Feed abonnieren
- Thema als neu kennzeichnen
- Thema als gelesen kennzeichnen
- Diesen Thema für aktuellen Benutzer floaten
- Lesezeichen
- Abonnieren
- Drucker-Anzeigeseite