This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/30964] optional arguments to random_seed
- From: "fxcoudert at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 28 May 2007 20:48:38 -0000
- Subject: [Bug fortran/30964] optional arguments to random_seed
- References: <bug-30964-10391@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #6 from fxcoudert at gcc dot gnu dot org 2007-05-28 20:48 -------
The following two codes are handled differently:
$ cat u.f90
call foo()
contains
subroutine foo(x)
integer, dimension(:), optional :: x
interface
subroutine bar(x)
integer, dimension(:), optional :: x
end subroutine bar
end interface
call bar(x)
end subroutine foo
end
$ cat v.f90
call foo()
contains
subroutine foo(x)
integer, dimension(:), optional :: x
call random_seed(get=x)
end subroutine foo
end
For the first one, gfc_conv_missing_dummy() is called, which leads to correct
code. For the second one, gfc_conv_missing_dummy() is not called, leading to
wrong-code.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30964