This is the mail archive of the gcc-patches@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]

Re: [patch, fortran] PR 56519: Reject impure intrinsic subroutines in DO CONCURRENT


Thomas Koenig wrote:
the attached patch rejects impure subroutines, such as RANDOM_NUMBER,
within DO CONCURRENT.
Regression-tested.  OK for trunk?

Okay - and thanks for the patch. Unrelated to changes in your patch, I am a bit unhappy about:

* Proliferation of global variables
* Magic values (0, 1, 2)
* Badly translatable strings: "â inside a DO CONCURRENT %s", âgfc_do_concurrent_flag == 2 ? "mask" : "block"

But as those are unchanged by your patch â

Tobias

2013-08-29  Thomas Koenig  <tkoenig@gcc.gnu.org>

         PR fortran/PR56519
         * gfortran.h:  Declare gfc_do_concurrent_flag as extern.
         * resolve.c:  Rename do_concurrent_flag to gfc_do_concurrent_flag.
         and make non-static.
         (resolve_function):  Use gfc_do_concurrent_flag instead of
         do_concurrent_flag.
         (pure_subroutine):  Likewise.
         (resolve_code):  Likewise.
         (resolve_types):  Likewise.
         * intrinsic.c (gfc_intrinsic_sub_interface):  Raise error for
         non-pure intrinsic subroutines within DO CONCURRENT.

2013-08-29  Thomas Koenig  <tkoenig@gcc.gnu.org>

         PR fortran/PR56519
         * gfortran.dg/do_concurrent_3.f90:  New test case.


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