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/66377] [F95] Wrong-code with equivalenced array in module


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

kargl at gcc dot gnu.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |kargl at gcc dot gnu.org

--- Comment #1 from kargl at gcc dot gnu.org ---
Here's a slightly different testcase, which works as expected.

module constant
  integer x1, x2, y1, y2
  equivalence (y1,x1), (x2,y2)
end module

program test
  use constant
  y1 = 1
  x2 = 2
  call another()
contains
  subroutine another()
    use constant, only : x1, y2
    if (x1 /= 1 .or. x2 /= 2) call abort
  end subroutine
end program

Thus, there is something about the "arrayness" of x in
the original testcase that matters.  Off-by-one maybe?


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