Sun Fortran 90 compiler error or not?

From: Bastiaan Braams (braams_at_courant.nyu.edu)
Date: 05/30/04


Date: 30 May 2004 14:47:21 -0700

What does the newsgroup make of the following? I'm working on a Sun
Solaris machine and my compilation fails with a segmentation fault.
The offending program follows, reduced to an essential minimum that
still produces the fault.

> f90 -V
f90: Forte Developer 7 Fortran 95 7.0 Patch 111714-09 2003/10/15

> f90 -O3 tmp.f90
"tmp.f90", Line = 26, Column = 1: INTERNAL: Interrupt: Segmentation Fault

> cat tmp.f90
MODULE m0
implicit none
private
integer, parameter, public :: m0_dim(0:3) = (/ 0, 1, 2, 3 /)
END MODULE m0
MODULE m1
use m0
implicit none
private
public :: m1_f
CONTAINS
FUNCTION m1_f (d) RESULT (w)
integer, intent (in) :: d
integer :: w(0:m0_dim(d)-1)
w = 0
return
END FUNCTION m1_f
END MODULE m1
PROGRAM main
use m0
use m1
implicit none
integer, parameter :: d=2
integer :: w(0:m0_dim(d)-1)
w = m1_f(d) ; write (*,*) w
write (*,*) m1_f(d)
stop
END PROGRAM main

Bas Braams

--
braams@mathcs.emory.edu


Relevant Pages

  • Re: Confusion with variables in modules
    ... means to share information within the module, you can use the PRIVATE ... This goes right by the "implicit none" (which I do see that the OP ... use mod2, only: i, j, k ... declaration) so that the compiler can help you enforce this. ...
    (comp.lang.fortran)
  • Re: Fun with renames
    ... If any of the USE statements for a given module has a rename clause, ... implicit none ...
    (comp.lang.fortran)
  • Trying to find a workaround for PR47034
    ... implicit none ... Components of structure constructor 'c_ptr' at are PRIVATE ... See for instructions. ... intrinsic type inside a derived type: ...
    (comp.lang.fortran)
  • PRIVATE type of PUBLIC procedure error: standard conformance question.
    ... I have the following module that defines a derived type: ... implicit none ... type(mytype_type), intent:: mytype ...
    (comp.lang.fortran)
  • Question about use and host association
    ... IMPLICIT NONE ... PRIVATE ... SUBROUTINE mytype_Write ... Is this compiler message bogus, or am I misunderstanding something about use and/or host ...
    (comp.lang.fortran)