Extracted form
http://groups.google.com/group/comp.lang.fortran/browse_thread/thread/c553e0034bab977c
(see pr34199) the following code:

module mod 
   implicit character(len=*,kind=kind('A')) (Q) 
   parameter(Q1 = 'Test Me!') 
   parameter(Q2 = 'Test Me Too!') 
   contains 
      subroutine sub(Q3) 
         write(*,*) '#'//Q3//'#' 
      end subroutine sub 
end module mod 
program startest 
   use mod 
   implicit none 
   write(*,*) '#'//Q1//'#' 
   write(*,*) '#'//Q2//'#' 
   call sub('Test Me More!') 
end program startest 

when compiled with gfortran 4.3.2, gives the expected (by me) output:

 #Test Me!#
 #Test Me Too!#
 #Test Me More!#

while when compiled with gfortran 4.4.0, it gives:

 #Test Me!#
 #Test Me #
 #Test Me #


-- 
           Summary: [4.4 Regression] implicit
                    character(len=*,kind=kind('A')) (Q) ... no longer gives
                    the right answer.
           Product: gcc
           Version: 4.4.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: dominiq at lps dot ens dot fr


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

Reply via email to