This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug fortran/84276] Invalid error for valid statement function


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84276

--- Comment #7 from Steve Kargl <sgk at troutmask dot apl.washington.edu> ---
Ugh.  Statement functions should be removed from the Standard.
The simply fix, of course, does not work if someone is clever
and uses keywords in a reference that involves a statement
function.

      subroutine step(hh, h, s, w)
      real, intent(inout) :: h, hh, s
      real, intent(out) :: w
      real :: qofs
      integer i
      qofs(s, i) = i * s
      i = 42
      w = qofs(hh, i)
      w = qofs(i = i, s = hh)
      end subroutine step

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]