This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

g77 of egcs-1.0.2/1.0.3a returns exit code 1 for argument type mismatch


Hello,

I got a non-zero exit status from g77 in egcs-1.0.2 and egcs-1.0.3a for a Fortran source shown below, and could not get any object.
 Is this a bug in g77/egcs or an expected behavior ?

*--------------------------------------------------------------------
      subroutine AA( a,b,c,i )
      real*8 a,b,c
      integer i     
C     
C
      return  
      end     
C     
      subroutine BB( a,b,c,d )
      real*8 a,b,c,d 
C    
      call AA( a,b,c,d )
      return  
      end
*--------------------------------------------------------------------

G77 claims as follows, but the message looks reasonable (the argument type mismatch might be intentional !!). The problem is that g77 of egcs terminates with exit status 1 and remains no object file.

---------------------------------------------------
AA.f: In subroutine `bb':
AA.f:1: 
         subroutine AA( a,b,c,i )
                    1
AA.f:12: (continued):
         call AA( a,b,c,d )
              2
Argument #4 (named `i') of `aa' is one type at (2) but is some other type at (1) [info -f g77 M GLOBALS]
---------------------------------------------------

An orignal version of g77 (g77 0.5.20) compiles the source normally, and g77 of egcs compiles succesfully when the two subroutines are on separate files.

I got this error on Linux/Slackware Kernel 2.0.12 (1.0.2), Linux/Alpha Kernel 2.1.88 (egcs1.0.2,1.0.3a) and HP-UX 10.20 (egcs1.0.2).

 ===================================================================
 Makoto Sasaki  : The Japan Research Institute Ltd.
                  sasaki@tyo.sci.jri.co.jp


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]