Bug 160853 - gfortran internal error for equivalence with character string
Summary: gfortran internal error for equivalence with character string
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: gcc
Version: 4
Hardware: i386
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Jakub Jelinek
QA Contact:
URL:
Whiteboard:
: 163800 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2005-06-17 20:18 UTC by Patrice Dumas
Modified: 2007-11-30 22:11 UTC (History)
1 user (show)

Fixed In Version: 4.0.1-4.fc4
Clone Of:
Environment:
Last Closed: 2005-07-27 18:14:42 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Patrice Dumas 2005-06-17 20:18:15 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; fr; rv:1.7.8) Gecko/20050524 Fedora/1.0.4-4 Firefox/1.0.4

Description of problem:
The following program compiles fine with g77, but leads to an internal error with gfortran:

      SUBROUTINE t2
      CHARACTER  CA*1
      CHARACTER*1  CQ(1)
      EQUIVALENCE (CQ(1),CA(1:1))
      END

[dumas@chapelle dzebra]$ gfortran -c -o res.o t2.f
 In file t2.f:5

      END                                                               
                                                                       1
 Internal Error at (1):
 find_array_spec(): Missing spec


In a similar code, but with an undeclared array, there is the same error message. This time the code is broken, but te error message is wrong:
      SUBROUTINE t     
      EQUIVALENCE (I, J(1))
      END
When compiled leads to

[dumas@chapelle dzebra]$  gfortran -c -o t.o  t.f 
 In file t.f:3

      END                                                               
                                                                       1
 Internal Error at (1):
 find_array_spec(): Missing spec

Version-Release number of selected component (if applicable):
gcc-gfortran-4.0.0-11

How reproducible:
Always

Steps to Reproduce:
1.try to compile the programs above
2.
3.
  

Actual Results:   Internal Error at (1):
 find_array_spec(): Missing spec


Expected Results:  a fine compilation

Additional info:

Comment 1 Patrice Dumas 2005-06-18 23:03:58 UTC
The first has allready been submitted in gcc as

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18833

Comment 2 Jakub Jelinek 2005-07-21 08:04:14 UTC
*** Bug 163800 has been marked as a duplicate of this bug. ***

Comment 4 Jakub Jelinek 2005-07-27 18:14:42 UTC
Should be fixed in gcc-4.0.1-4.fc4.


Note You need to log in before you can comment on or make changes to this bug.