Shape intrinsic does not allow scalar arguments as required by f90/f95/f03 standards. Example code follows: program test_shape ! Segmentation fault generated when executable executed integer :: i print *, shape( i ) ! Shape of a scalar allowed by f90, f95, f03 ! standards. end program test_shape
Kind intrinsic with character argument in type declaration fails: Example follows: ! Compiler version: ! GNU Fortran (GCC) 4.2.4 (Ubuntu 4.2.4-1ubuntu3) ! Copyright (C) 2007 Free Software Foundation, Inc. character (len = 3, kind = kind("a" ) c ! Compiler fails with internal error -- invalid syntax ! character (len = 3, kind = kind("a") ) c ! Fails compilation -- invalid kind ! value returned -- that is, minus ! integer huge. Notice the ! kind("a") is correctly returned ! as 1 in print statement below and ! kind=1 works in a character ! declaration. ! character (len = 3, kind = 1) c ! Works c = "b" print *, kind("a"), c end program -- Summary: Fortran shape and kind intrinsic Product: gcc Version: 4.0.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: carbess at swcp dot com http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37999