------- Comment #7 from paulthomas2 at wanadoo dot fr 2006-08-30 20:01 ------- Subject: Re: [4.2 Regression]: fold_convert fails for Fortran operator
hjl at lucon dot org wrote: >------- Comment #6 from hjl at lucon dot org 2006-08-30 19:40 ------- >Before the change, gfc_get_derived_type will search a module to reuse >TREE_TYPE. >The current one will create a new TREE_TYPE for the same type. But fold_convert >has > > if (type == orig) > return arg; > >Although TYPE and ORIG are the same type, they have different memory locations. >fold_convert doesn't handle it. > > > > HJ I am just about to post the patch - all the regressions that I have had to deal with emanating from the revamp of derived type association have been very subtle to understand... except this one, which is down to stupidity on my part. The sad thing is that I though that I was being clever too! However, I have to say that I am really surprised that none of my tests caught it. I am sorry for the inconvenience. Paul -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28908