Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Valued Contributor III
4 Views

Parameterized Derived Types: (PDTs) internal compiler error with length-type parameter and a structure constructor

Fyi for readers - an incident has been submitted at the OSC for the following:

   type :: t(ell)
      integer, len :: ell
      character(len=1) :: s(ell)
   end type

   integer, parameter :: N = 2
   type(t(ell=:)), allocatable :: foo

   foo = t(ell=N)( s=transfer(source=repeat("x",ncopies=N), mold=[ character(len=1) :: ], size=N) )

end

Compiler output:

xxx>ifort /c /standard-semantics /warn:all /stand p.f90
Intel(R) Visual Fortran Intel(R) 64 Compiler for applications running on Intel(R) 64,
Version 18.0.0.124 Build 20170811
Copyright (C) 1985-2017 Intel Corporation. All rights reserved.

p.f90(9): catastrophic error: **Internal compiler error: internal abort** Please
report this error along with the circumstances in which it occurred in a Softwa
re Problem Report. Note: File and line given may not be explicit cause of this
error.
compilation aborted for p.f90 (code 1)

xxx>

 

0 Kudos
4 Replies
Highlighted
Valued Contributor II
4 Views

Call me a Luddite but I have

Call me a Luddite but I have yet to touch a PDT even with a long stick, and I think I will ignore them for some time yet along with Visual Studio 2017 and venomous snakes. 

0 Kudos
Highlighted
Valued Contributor III
4 Views

Quote:andrew_4619 wrote:

andrew_4619 wrote:

.. I have yet to touch a PDT ..

@Andrew,

See this thread and try out code in Quote #30,

https://software.intel.com/en-us/forums/intel-visual-fortran-compiler-for-windows/topic/746406

PDTs can be very powerful and useful. 

Unless more users try them out, the bugs will remain "hidden" in the compiler body like a virus for a long time.

0 Kudos
Highlighted
Valued Contributor III
4 Views

Here's another case that has

Here's another case that has been turned in at the OSC:

   type :: t(ell) 
      integer, len :: ell 
   end type 

   type :: u 
      type(t(ell=:)), allocatable :: x 
   end type 

   type(t(ell=:)), allocatable :: foo 
   type(u) :: bar 

   allocate( t(ell=1) :: foo ) 

   bar = u( x=foo ) 

end 
xxx>ifort /c /standard-semantics /warn:all /stand p.f90
Intel(R) Visual Fortran Intel(R) 64 Compiler for applications running on Intel(R) 64,
Version 18.0.0.124 Build 20170811
Copyright (C) 1985-2017 Intel Corporation.  All rights reserved.

p.f90(14): catastrophic error: **Internal compiler error: internal abort** Pleas
e report this error along with the circumstances in which it occurred in a Softw
are Problem Report.  Note: File and line given may not be explicit cause of this
 error.
compilation aborted for p.f90 (code 1)

xxx>

 

0 Kudos
Highlighted
New Contributor II
4 Views

If you are a Luddite, Andrew,

If you are a Luddite, Andrew, then I'm a pre-Luddite.  I'm still using IVF 11.0.075, which I find completely satisfactory.

0 Kudos