[flang] Add more qualification when creating names for compiler-generated USEs
authorPeter Klausler <pklausler@nvidia.com>
Sat, 11 Jun 2022 15:39:38 +0000 (08:39 -0700)
committerPeter Klausler <pklausler@nvidia.com>
Wed, 15 Jun 2022 21:18:28 +0000 (14:18 -0700)
commitbcad53e13175ef4f98764c7fa3588a7915dffe62
tree4d38a47cdd4e65b7208f8cce733b79b1e3925fa9
parentf6253eb9ba3838922c1b4750f8b3dcb7c30ffd38
[flang] Add more qualification when creating names for compiler-generated USEs

When generic resolution finds its specific procedure in a module,
and that specific procedure is not use-associated into the local scope
(perhaps because it was PRIVATE, perhaps because the generic was
use-associated with ONLY:), we create a new use-association with
a renaming.  The name constructed for this renaming needs to be
additionally qualified with the module name of the specific procedure
in order to avoid clashing with another specific of the same name
that may have previously been use-associated in the same way from
a distinct module.

Differential Revision: https://reviews.llvm.org/D127790
flang/lib/Semantics/expression.cpp
flang/test/Semantics/modfile39.f90