------- Comment #3 from fxcoudert at gcc dot gnu dot org  2006-10-02 15:24 
-------
Here's a detailed analysis of the current testsuite failures with Andrew's
patches from PR22368 (all patches applied) on i686-linux.

First testcase (from actual_array_constructor_1.f90):

  subroutine bar(a)
    character(len=*) :: a
    call foo((/ a, 'g' /))
  end

The error message issued is
actual_array_constructor_1.f90: In function ‘bar’:
actual_array_constructor_1.f90:3: error: statement types mismatch
(*D.941)[S.9D.942]{lb: 0 sz: _a.8D.939} = D.946;

charD.14[1:_aD.902]
charD.14[1:1]
actual_array_constructor_1.f90:3: internal compiler error: verify_stmts failed



Second testcase:

  interface
    pure function double (string)
      character (len = *), intent (in) :: string
      character (len = len (string)) :: double
    end function double
  end interface

  print *, f5("foo")

contains
  function f5 (string)
    character (len = *) :: string
    character (len = len (double (string))) :: f5
    f5 = ''
  end function f5

end

returns (at -O1):

char_result_1.f90: In function ‘MAIN__’:
char_result_1.f90:1: error: statement types mismatch
D.949_16 = stringD.939_11;

charD.14[1:3] &
charD.14[1:_stringD.907] &
char_result_1.f90:1: internal compiler error: verify_stmts failed
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.


Third testcase:

  real c
  if (loc(c) == 0) call abort
  end

produces:

loc_2.f90: In function ‘MAIN__’:
loc_2.f90:2: error: types mismatch in comparsion
<unnamed type>

int4D.2

D.903 == 0;

loc_2.f90:2: internal compiler error: verify_stmts failed



Fourth testcase:

  call foo("g")
contains
  subroutine foo (s)
    character(*), optional :: s
    if (present(s)) call abort
  end subroutine
end

produces

missing_optional_dummy_1.f90: In function ‘MAIN__’:
missing_optional_dummy_1.f90:1: error: types mismatch in comparsion
charD.14[1:_sD.904] *

charD.14[1:1] *

sD.913_1 != 0B;

missing_optional_dummy_1.f90:1: internal compiler error: verify_stmts failed


-- 

fxcoudert at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |fxcoudert at gcc dot gnu dot
                   |                            |org
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
   Last reconfirmed|0000-00-00 00:00:00         |2006-10-02 15:24:35
               date|                            |


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

Reply via email to