This is an archive of the discontinued LLVM Phabricator instance.

[flang] Dial some errors down to warnings for ASSOCIATED()
ClosedPublic

Authored by klausler on Jul 22 2022, 12:16 PM.

Details

Summary

When a procedure pointer is associated with a procedure target, f18
will emit hard error messages if the pointer is incompatible with the
target in a way that would cause the program to not work if the
procedure pointer were actually called. However, in the context of
the ASSOCIATED() intrinsic, the compiler should not consider a query
to be a compilation-time error if the pointer and the target are
incompatible. The standard gives us sufficient wiggle room here
to treat these cases as warnings.

Attempts to use ASSOCIATED to test whether a procedure pointer is
associated with a data object, or vice versa, remain errors.

Diff Detail

Event Timeline

klausler created this revision.Jul 22 2022, 12:16 PM
Herald added a project: Restricted Project. · View Herald TranscriptJul 22 2022, 12:16 PM
Herald added a subscriber: jdoerfert. · View Herald Transcript
klausler requested review of this revision.Jul 22 2022, 12:16 PM
This revision is now accepted and ready to land.Jul 25 2022, 7:28 AM