[Patch, fortran] PR112460 - [PDT] ICE with parameterized derived types (incorrect code, should be rejected)
Paul Richard Thomas
paul.richard.thomas@gmail.com
Sun Jan 11 13:41:30 GMT 2026
Hi All,
This patch detects mismatched, constant PDT type specification parameters
in array constructors and assignment. It is completely straightforward and
sufficiently described by the ChangeLog.
In preparing the testcase, I noticed that assignment of one PDT variable
array to another was not being scalarized but, instead being copied
directly. While this is OK for PDTs with no len parameters, parameterized
arrays or strings, it is not generally correct. The fix is the one-liner in
trans-expr.cc.
Regtests on FC43/x86_64 - OK for mainline?
Paul
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://gcc.gnu.org/pipermail/gcc-patches/attachments/20260111/a2caacd4/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Change.Logs
Type: application/octet-stream
Size: 833 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/gcc-patches/attachments/20260111/a2caacd4/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: submit.diff
Type: text/x-patch
Size: 6593 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/gcc-patches/attachments/20260111/a2caacd4/attachment.bin>
More information about the Gcc-patches
mailing list