This is an archive of the discontinued LLVM Phabricator instance.

[flang] Fixed initialization of c_ptr/c_funptr arrays.
ClosedPublic

Authored by vzakhari on May 18 2023, 1:03 PM.

Details

Summary

When lowering ends up outlining the initialization of an entity
containing an array of c_ptr/c_funptr it is treating the array
initializer as scalar due to the missing check for the rank.
When initializing non-0 rank c_ptr/c_funptr entity it has to
recurse via genConstantValue().

Diff Detail

Event Timeline

vzakhari created this revision.May 18 2023, 1:03 PM
Herald added a project: Restricted Project. · View Herald TranscriptMay 18 2023, 1:03 PM
vzakhari requested review of this revision.May 18 2023, 1:03 PM
This revision is now accepted and ready to land.May 18 2023, 2:09 PM
This revision was automatically updated to reflect the committed changes.