This is an archive of the discontinued LLVM Phabricator instance.

[flang] Don't add a source range to a type instantiation's scope
ClosedPublic

Authored by klausler on Feb 15 2023, 11:16 AM.

Details

Summary

A type instantiation's scope doesn't require a source range, as we don't
need/want it to be the result of SemanticsContext::FindScope(), and
adding the original type's source range to the scope of one of its
instantiations has the side effect of expanding the source range of
all of its parents to include the original type definition, which
breaks FindScope() for any scope including a type instantiation.

Diff Detail

Event Timeline

klausler created this revision.Feb 15 2023, 11:16 AM
Herald added a project: Restricted Project. · View Herald TranscriptFeb 15 2023, 11:16 AM
klausler requested review of this revision.Feb 15 2023, 11:16 AM
This revision is now accepted and ready to land.Feb 15 2023, 12:03 PM