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] PR38718: add simplifier for MERGE


Daniel Kraft wrote:
Daniel Franke wrote:
Hi all.

MERGE is an elemental intrinsic function and as such allowed in initialization expressions. However, up until now, there was no simplifier for MERGE, thus init expr using it were rejected (not directly but with a somewhat cryptic error).
The PR lists more elemental functions were simplifiers are missing, but MERGE is the only one from F95.



gcc/fortran: 2009-01-04 Daniel Franke <franke.daniel@gmail.com>

    PR fortran/38718
    * simplify.c (gfc_simplify_merge): New.
    * intrinsic.h (gfc_simplify_merge): New prototype.
    * intrinsic.c (add_functions): Added simplification for MERGE.

gcc/testsuite:
2009-01-04  Daniel Franke  <franke.daniel@gmail.com>

    PR fortran/38718
    * gfortran.dg/merge_init_expr.f90: New.


Regression tested on i686-pc-linux-gnu. Ok for trunk?

Ok. I'm not sure whether we should wait for 4.5, but my opinion is that the change is quite clear and it should be ok for trunk, it actually fixes a rejects-valid bug.


Thanks for fixing this!

Daniel

I concur, a rejects valid is OK.

Jerry


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