ICE on defined operator with parenthetical LHS argument
Rouson, Damian
rouson@sandia.gov
Fri Nov 5 21:41:00 GMT 2010
Gfortran 4.6.0 20100925 halts with an ICE on the following module and main
program produce an ICE as shown below the code. It appears that having the
parenthesis around the left-hand-side argument "(u)" is required to produce
the ICE. This is a greatly reduced example in which the parentheses are
superflous. In the actual code, I need the parentheses because they contain
a much longer expression.
$ cat field_main.f03
module field_module
implicit none
type ,abstract :: field
contains
procedure(field_op_real) ,deferred :: multiply_real
generic :: operator(*) => multiply_real
end type
abstract interface
function field_op_real(lhs,rhs)
import :: field
class(field) ,intent(in) :: lhs
real ,intent(in) :: rhs
class(field) ,allocatable :: field_op_real
end function
end interface
end module
program main
use field_module
implicit none
class(field) ,pointer :: u
u = (u)*2.
end program
$ gfortran field_main.f03
f951: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.
$ gfortran --version
GNU Fortran (GCC) 4.6.0 20100925 (experimental)
Copyright (C) 2010 Free Software Foundation, Inc.
GNU Fortran comes with NO WARRANTY, to the extent permitted by law.
You may redistribute copies of GNU Fortran
under the terms of the GNU General Public License.
For more information about these matters, see the file named COPYING
More information about the Fortran
mailing list