parameter_array_section_1.f90

来自「用于进行gcc测试」· F90 代码 · 共 25 行

F90
25
字号
! { dg-do compile }! Tests the fix for PR29821, which was due to failure to simplify the! array section, since the section is not constant, provoking failure! to resolve the argument of SUM and therefore to resolve SUM itself.!! Contributed by Harald Anlauf  <anlauf@gmx.de>!module gfcbug45  implicit nonecontains  subroutine foo     real, external :: mysum    integer :: i    real    :: a    real, parameter :: eps(2) = (/ 1, 99 /)    i = 1    a = sum (eps(i:i+1) * eps)    print *, a  end subroutine fooend module gfcbug45  use gfcbug45  call fooend! { dg-final { cleanup-modules "gfcbug45" } }

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?