[Patch, Fortran] PR fortran/37429: Missing rank on type-bound procedure call expressions
Daniel Kraft
d@domob.eu
Tue Sep 9 16:06:00 GMT 2008
Hi,
my type-bound procedure implementation did not save the rank on
expressions representing calls to type-bound functions (they had their
"rank" field always set to zero), which lead to the problem in PR 37429.
This patch sets the rank on resultion to that of the target procedure's
array spec. I'm not completely sure if I've got to set the shape, too,
if possible, but the attached patch works just fine for the test cases
and gfc_match_rvalue, too, sets only the rank for ordinary functions.
So I'm quite sure the patch is complete and right as it is. The
shape-mismatch check in the test-case works.
I'm not sure whether I should include the second test
(typebound_call_8.f03) as it is mostly a subset of the _7 test; however,
without my patch _8 ICE'd while _7 "just" missed the diagnostic (but
those two are probably thightly coupled). What do you think?
No regressions on GNU/Linux-x86-32. Ok to commit? Sorry for this in
the first place :)
Cheers,
Daniel
--
Done: Arc-Bar-Cav-Sam-Val-Wiz, Dwa-Elf-Gno-Hum-Orc, Law-Neu-Cha, Fem-Mal
To go: Hea-Kni-Mon-Pri-Ran-Rog-Tou
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: patch.changelog
URL: <http://gcc.gnu.org/pipermail/fortran/attachments/20080909/b8b60b07/attachment.ksh>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: patch.diff
URL: <http://gcc.gnu.org/pipermail/fortran/attachments/20080909/b8b60b07/attachment-0001.ksh>
More information about the Fortran
mailing list