Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
New Contributor I

Output problem of parameterized derived type

Hi, there's  a problem of outputting parameterized derived type. Assume this:

program main
    implicit none

    type :: test(l)
        integer, len :: l = 99
        character(l) :: s
    end type test

    type(test(10)) :: str = test(10)("1234567890")

    write(*,*) str%s

end program main

This generates a runtime error of memory conflict when accessing libifcoremdd.dll, so where is the mistake ? Appreciate any reply.

 

0 Kudos
4 Replies
Highlighted

Can you provide the compiler

Can you provide the compiler version and the compilation command line? I tried  both 16.0 update 3 and the latest 17.0. None of them produced the error.

 

Thanks,

Xiaoping Duan

Intel Customer Support

0 Kudos
Highlighted
New Contributor I

I'm using Intel(R) Visual

I'm using Intel(R) Visual Fortran Compiler XE 15.0.6.285 [IA-32] and the command line:

Compile:

/nologo /debug:full /Od /warn:interfaces /module:"Debug\\" /object:"Debug\\" /Fd"Debug\vc140.pdb" /traceback /check:bounds /check:stack /libs:dll /threads /dbglibs /c

Link:

 /OUT:"Debug\Project.exe" /INCREMENTAL:NO /NOLOGO /MANIFEST /MANIFESTFILE:"Debug\Project.exe.intermediate.manifest" /MANIFESTUAC:"level='asInvoker' uiAccess='false'" /DEBUG /PDB:"D:\Project\Project\Debug\Project.pdb" /SUBSYSTEM:CONSOLE /STACK:10000000,10000000 /IMPLIB:"D:\Project\Project\Debug\Project.lib"

Thanks.

0 Kudos
Highlighted

I can reproduce the error

I can reproduce the error using 15.0 compiler. It should be a compiler bug which has already been fixed in the newer 16.0 and 17.0 version. So please upgrade your compiler to the newer version.

 

Thanks,

Xiaoping Duan

Intel Customer Support

0 Kudos
Highlighted
New Contributor I

Quote:Xiaoping D. (Intel)

Xiaoping D. (Intel) wrote:

I can reproduce the error using 15.0 compiler. It should be a compiler bug which has already been fixed in the newer 16.0 and 17.0 version. So please upgrade your compiler to the newer version.

 

Thanks,

Xiaoping Duan

Intel Customer Support

That's OK, thanks a lot.

0 Kudos