OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gfortran.dg/] [array_constructor_22.f90] - Blame information for rev 801

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 694 jeremybenn
! { dg-do compile }
2
! PR34990 ICE in gfc_typenode_for_spec, at fortran/trans-types.c:842
3
! Test case that of the reporters.
4
module test
5
   implicit none
6
   contains
7
      function my_string(x)
8
         integer i
9
         real, intent(in) :: x(:)
10
         character(0) h4(1:minval([(1,i=1,0)],1)) ! { dg-warning "will be executed zero times" }
11
         character(0) sv1(size(x,1):size(h4))
12
         character(0) sv2(2*lbound(sv1,1):size(h4))
13
         character(lbound(sv2,1)-3) my_string
14
 
15
         do i = 1, len(my_string)
16
            my_string(i:i) = achar(modulo(i-1,10)+iachar('0'))
17
         end do
18
      end function my_string
19
end module test
20
 
21
program len_test
22
   use test
23
   implicit none
24
   real x(7)
25
 
26
   write(*,*) my_string(x)
27
end program len_test
28
! { dg-final { cleanup-modules "test" } }

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.